diff options
author | Narayan Desai <desai@mcs.anl.gov> | 2008-03-08 15:18:11 +0000 |
---|---|---|
committer | Narayan Desai <desai@mcs.anl.gov> | 2008-03-08 15:18:11 +0000 |
commit | 07467bbc04b77453a9d27a5dd82729d304eddb70 (patch) | |
tree | ffcb671d5ea4f32443f956c4ef3f4b4a4a0a323d /src/lib/Client | |
parent | 166b1428ba69e72d9e3b75ee0293a38025bc4806 (diff) | |
download | bcfg2-07467bbc04b77453a9d27a5dd82729d304eddb70.tar.gz bcfg2-07467bbc04b77453a9d27a5dd82729d304eddb70.tar.bz2 bcfg2-07467bbc04b77453a9d27a5dd82729d304eddb70.zip |
Fix xinetd service management with the chkconfig driver (Patch from Gordon Messmer) [bugfix]
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@4403 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Client')
-rw-r--r-- | src/lib/Client/Tools/Chkconfig.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/lib/Client/Tools/Chkconfig.py b/src/lib/Client/Tools/Chkconfig.py index e711d35ae..382a575d0 100644 --- a/src/lib/Client/Tools/Chkconfig.py +++ b/src/lib/Client/Tools/Chkconfig.py @@ -25,8 +25,13 @@ class Chkconfig(Bcfg2.Client.Tools.SvcTool): # Ocurrs when no lines are returned (service not installed) entry.set('current_status', 'off') return False - if entry.get('type') == 'xinetd': - return entry.get('status') == srvdata[1] + if len(srvdata) == 2: + # This is an xinetd service + if entry.get('status') == srvdata[1]: + return True + else: + entry.set('current_status', srvdata[1]) + return False try: onlevels = [level.split(':')[0] for level in srvdata[1:] \ |