Red Hat Bugzilla – Bug 439361
chkconfig <name> lists usage message for unsupported service
Last modified: 2014-03-16 23:13:17 EDT
Description of problem:
When issuing chkconfig <name> with no extra arguments in order to check if a
service is enabled, and the service in question is missing, a chkconfig usage
message is printed. This is bit inconventient if you have setup scripts etc.
that that check if a certain service is present, and has been enabled.
In the past, chkconfig would just return with exit status 1 in this case, i.e.
have the same behaviour as for a service that's supported, but not enabled.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. chkconfig fakeservicename
chkconfig version 188.8.131.52 - Copyright (C) 1997-2000 Red Hat, Inc.
This may be freely redistributed under the terms of the GNU Public License.
usage: chkconfig --list [name]
chkconfig --add <name>
chkconfig --del <name>
chkconfig [--level <levels>] <name> <on|off|reset|resetpriorities>
Exit status is 1
No output exit status is 1
I'm not interested in made-up service names like the one above of course, but I
want to be able to use chkconfig to check the status of services that are
associated with optional software components. I want exactly the same behaviour
whether these are installed and disabled, or not installed at all.
*** This bug has been marked as a duplicate of 226804 ***