IP Address: 38.107.191.102
Hostname: 38.107.191.102
Enabling and disabling services during start up in Linux
How to set services to start & stop automatically.
Red Hat and Red Hat based Linux distributions make use of the script called chkconfig to enable and disable the system services running in Linux.
For example, to enable the apache webserver to start in certain run levels, you use the chkconfig script to enable it in the desired run levels as follows:
# chkconfig httpd --add
# chkconfig httpd on --level 2,3,5
This will enable the apache webserver to automatically start in the run levels 2, 3 and 5. You can check this by running the command:
# chkconfig --list httpd
One can also disable the service by using the off flag as shown below:
# chkconfig httpd off
# chkconfig httpd --del
Red Hat also has a useful script called service which can be used to start or stop any service. Taking the previous example, to start apache webserver, you execute the command:
# service httpd start
and to stop the service…
# service httpd stop
The options being start, stop and restart which are self explanatory.
Sponsored Ads:
Ad Space
Random Articles:
Terminal Services Temporary Client License Expiration
How can I resolve the warning “Your terminal services temporary client license will expire in x days.”
How can I uninstall Trend Officescan?
Recent Articles:
Outbound Call Problems with Cisco Call Manager
Users unable to make outbound 10 digit calls when using MGCP
Reset Websense Manager Password
How can I reset the password for the WebsenseAdministrator?
How can I disable SSL version 2 in Apache and IIS?
Save to del.icio.us