The chkconfig command can be used to control services at each runlevel. It can also be used to start or stop services during system startup.


The syntax of the chkconfig command is:

# chkconfig [options] [service] [subcommand]

The following are some subcommands and options that can be used with chkconfig to control services.

Option Used To
{service} on Enable a service to be started on boot.
{service} off Disable a service so that it is no longer started on boot.
{service} reset Reset the status of a service.
–level {runlevel} Specify the runlevel in which to enable or disable a service.

chkconfig Command Examples

1. To see the current runlevel states for all the services:

2. To list a particular service status:

3. To add a service script into the runlevel:

# chkconfig --add /etc/init.d/ 

4. To delete a service script from the runlevels:

# chkconfig --del /etc/init.d/ 

5. To specify the runlevel for any service, which should pertain to it: