LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (http://www.linuxquestions.org/questions/linux-server-73/)
-   -   Starting Services Automatically (http://www.linuxquestions.org/questions/linux-server-73/starting-services-automatically-760687/)

Arty Ziff 10-08-2009 11:03 PM

Starting Services Automatically
 
Apache and MySQL not starting automatically on reboot.

How do I configure this?

OS = CentOS v5

- Thanks

bathory 10-09-2009 12:11 AM

How did you install apache and mysql?
If you have installed both using your package manager it should have already setup the appropriate services. Use
Code:

chkconfig --list
to check the status of the 2 services, and
Code:

chkconfig httpd --level 2345 on
chkconfig mysqld --level 2345 on

to enable them.

Regards

avijitp 10-09-2009 12:50 AM

If Apache and MySQL server is a rpm based installation then enabling it to start at run level 3 (which should be your default run level) though the above commands should fix the issue for you.

If they are compiled version, then you need to add a start/stop script in /etc/init.d and then create symbolic links to them in /etc/rc.d/rc3.d for the S/K scripts for each of them.


All times are GMT -5. The time now is 09:26 AM.