2

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!

Axxmasterr
  • 7,966

2 Answers2

4

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/

2

You can also use chkconfig

Example:

chkconfig [servicename] on

This normally actives the service on runlevel 3 and 5.

BinaryMisfit
  • 20,879