I have a stand alone server application that I would like to run automatically when my red hat box starts up. My default run level is 5 but I want to make sure it works both in run level 3 & 5.
Answers appreciated!
I have a stand alone server application that I would like to run automatically when my red hat box starts up. My default run level is 5 but I want to make sure it works both in run level 3 & 5.
Answers appreciated!
There's /etc/rc.d/rcX.d directory for each runlevel X. Symlink apropriate [S]tart and/or [K]ill scripts to /etc/rc.d/rc3.d/ and /etc/rc.d/rc5.d
The scripts are run as sorted by number. This way you can organize dependencies.
The scripts per se are in /etc/init.d/
You can also use chkconfig
Example:
chkconfig [servicename] on
This normally actives the service on runlevel 3 and 5.