fixes for insserv on SLES11
fixes #23700, seems SLES11 has diff behaviour of insserv these changes are compatible with debian/ubuntu.
This commit is contained in:
parent
fab2dfd1c6
commit
a86878c425
1 changed files with 3 additions and 3 deletions
|
@ -853,13 +853,13 @@ class LinuxService(Service):
|
|||
return
|
||||
|
||||
#
|
||||
# insserv (Debian 7)
|
||||
# insserv (Debian <=7, SLES, others)
|
||||
#
|
||||
if self.enable_cmd.endswith("insserv"):
|
||||
if self.enable:
|
||||
(rc, out, err) = self.execute_command("%s -n %s" % (self.enable_cmd, self.name))
|
||||
(rc, out, err) = self.execute_command("%s -n -v %s" % (self.enable_cmd, self.name))
|
||||
else:
|
||||
(rc, out, err) = self.execute_command("%s -nr %s" % (self.enable_cmd, self.name))
|
||||
(rc, out, err) = self.execute_command("%s -n -r -v %s" % (self.enable_cmd, self.name))
|
||||
|
||||
self.changed = False
|
||||
for line in err.splitlines():
|
||||
|
|
Loading…
Reference in a new issue