Posts tagged: chkconfig – Linux Service Auto Start/Stop

Mar 04 2010

chkconfig – Linux Service Auto Start/Stop

chkconfig – Linux Service Auto Start/Stop

The chkconfig command can be used to activate and deactivate services. If you use the chkconfig –list command, you will see a list of system services and whether they are started (on) or stopped (off) in runlevels 0-6

# chkconfig
chkconfig version 1.3.30.1 – 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
chkconfig –del
chkconfig [--level ]

1. chkconfig –list – will query any service in /etc/rc.d with each runlevel

$ chkconfig –list anacron
anacron 0:off 1:off 2:on 3:on 4:on 5:on 6:off

2. chkconfig –level <0/1/2/3/4/5/6> – Will be used to auto start/stop the service at each run level

chkconfig can be used to set a service to be started (or not) in a specific runlevel.

For example, to turn ntpd off in runlevels 3, 4, and 5, use the command:

chkconfig –level 345 ntpd off

Alibi3col theme by Themocracy