From: Thierry Parmentelat Date: Tue, 10 Nov 2015 15:04:37 +0000 (+0100) Subject: trace actions done on cgroups so we can check if this happens within the lifespan... X-Git-Tag: nodemanager-5.2-18~6 X-Git-Url: http://git.onelab.eu/?p=nodemanager.git;a=commitdiff_plain;h=1eccb35fa24dc6b7a8aa6a8922be2e776b8cc33e trace actions done on cgroups so we can check if this happens within the lifespan of the sliver --- diff --git a/cgroups.py b/cgroups.py index 7ccbf0b..43a549d 100644 --- a/cgroups.py +++ b/cgroups.py @@ -98,12 +98,14 @@ def write(name, key, value, subsystem="cpuset"): base_path = get_cgroup_path(name, subsystem) with open(os.path.join(base_path, key), 'w') as f: print >>f, value + logger.verbose("cgroups.write: overwrote {}".format(base_path)) def append(name, key, value, subsystem="cpuset"): """ Appends a value to the file key with the cgroup with name """ base_path = get_cgroup_path(name, subsystem) with open(os.path.join(base_path, key), 'a') as f: print >>f, value + logger.verbose("cgroups.append: appended {}".format(base_path)) if __name__ == '__main__': diff --git a/sliver_lxc.py b/sliver_lxc.py index c425a4c..320c546 100644 --- a/sliver_lxc.py +++ b/sliver_lxc.py @@ -117,8 +117,6 @@ class Sliver_LXC(Sliver_Libvirt, Initscript): arch = 'i686' - - refImgDir = os.path.join(Sliver_LXC.REF_IMG_BASE_DIR, vref) containerDir = os.path.join(Sliver_LXC.CON_BASE_DIR, name)