Red Hat Bugzilla – Bug 97650
chkconfig --add does not work as advertised
Last modified: 2007-04-18 12:54:53 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3) Gecko/20030312
Description of problem:
The chkconfig line at the top of the initscript is incorrectly formatted.
Version-Release number of selected component (if applicable):
2.1-8 and Raw Hide's 2.1.2-2
Steps to Reproduce:
1. Fresh install of mailman
2. run chkconfig --add mailman as root
3. run chkconfig --list mailman
Actual Results: Notice that mailman is listed as off for all run levels.
Expected Results: Mailman should have been listed as on for run levels 3, 4 and 5.
chkconfig --del seems to work properly.
This is deliberate behavior, it is Red Hat policy that you as a user must enable
a service, RPM's do not automatically start services upon installation. Perhaps
you may have missed the documentation in:
I've included the relevant excerpt below.
- Start the Mailman qrunner daemon
As of mailman version 2.1 mailman requires a service (daemon) to be
run for mailman to operate. RedHat does not ship RPM's that enable
services as part of package installation. You will need to enable
the mailman service if you want mailman to run.
To enable the mailman service after package installation you may run
the "serviceconf" GUI tool, or you may do the following on the
command line as root.
/sbin/service mailman start
To have the mailman service automatically start at certain run
levels (replace the runlevel below with your desired run levels, for
example to start mailman at run levels 3 and 5 runlevel would be 35:
/sbin/chkconfig --level runlevel mailman on
The /etc/init.d/mailman script states:
# On RedHat, and derivatives, install with "chkconfig --add mailman"
# chkconfig: - 98 12
# description: Mailman is the GNU Mailing List Manager, a program that \
# manages electronic mail discussion groups. For more \
# on GNU Mailman see http://www.list.org
# processname: mailmanctl
# config: /var/mailman/Mailman/mm_cfg.py
# pidfile: /var/mailman/data/qrunner.pid
When I run chkconfig --add mailman, then chkconfig --list mailman, it's off for
all run levels. This is the case on two of my RH 9 systems. Either fix it so
that chkconfig --add works, or change the blurb to say chkconfig --levels 345
mailman on. All you'd have to do is change the line from
# chkconfig: - 98 12
# chkconfig: 345 98 12
After the command "chkconfig --add mailman" it should be off for all levels.
BTW, the spec file does this so you don't need to do this manually.
The "add" verb does not turn services on at init time, therefore after
performing an "add" the fact that --list then says its off is the desired
behavior. All that "add" does is inform the init system of a new service init
script. It does not enable or turn on the service.
It is Red Hat policy that you must manually turn on the service at your desired
run levels. Therefore you must issue the "chkconfig --runlevel X mailman on"
command to turn on mailman at init time.
Perhaps I've misunderstood the problem you are stating, after you've read my
explanation do you still believe the behavior is wrong? If so please let me know
why and I'll try to fix it for you.
Ok, then that was my misunderstanding. chkconfig --add iptables adds the
service to run levels 2345, but I notice now that httpd doesn't work that way.