X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=initscript.py;h=cf9141c901945b1282c1e6f024584f903ad0e520;hb=9e596e6eb3c871ab25837903b0ed30f165d9d688;hp=152d25f3c4ebdd93a8e140ca304cfcf41600521b;hpb=5278c90a37dce3a7d81d173db85976a0b36e06f7;p=nodemanager.git diff --git a/initscript.py b/initscript.py index 152d25f..cf9141c 100644 --- a/initscript.py +++ b/initscript.py @@ -29,6 +29,7 @@ class Initscript: self.rerun_slice_vinit() else: logger.log("Initscript: %s: Removed obsolete initscript %s" % (self.name, sliver_initscript)) + def install_and_enable_vinit(self): "prepare sliver rootfs init and systemd so the vinit service kicks in" # the fact that systemd attempts to run old-style services @@ -70,9 +71,23 @@ class Initscript: """ suitable for systemd-based VMs """ - # how are we wrt slice re-creation if we just kill this stuff - # of course no initscript will trigger at all ... - return + + ########## + ########## initscripts : current status - march 2015 + ########## + # + # the initscripts business worked smoothly up to f18 inclusive + # with f20 and the apparition of machinectl, things started to + # behave really weird + # + # so starting with f20, after having tried pretty hard to get this right, + # but to no success obviously, and in order to stay on the safe side + # of the force, I am turning off the initscript machinery completely + # that is to say: the vinit.service does not get installed at all + # + if os.path.isfile('/usr/bin/machinectl'): + logger.log("WARNING: initscripts are not supported anymore in nodes that have machinectl") + return vinit_source = "/usr/share/NodeManager/sliver-systemd/vinit.service" vinit_unit_file = "/vservers/%s/usr/lib/systemd/system/vinit.service" % self.name