Manage Linux init or startup scripts

Filed under
HowTos

Init scripts are small shell programs that usually control services, also known as daemons. Other applications for init scripts involve simply controlling the state of something such as hdparm (HDD sleep timeouts), iptables (loading firewall rule-sets into the kernel) and setserial (COM port configuration).The /etc/init.d directory contains the scripts executed by init at boot time and when the init state.

Init scripts are also important during startup and shutdown (simply “runlevel” changes on *nix systems). If you take a look at the list of processes running on your machine (try ps auwx), chances are that the process with the lowest PID is called “init”. This is the parent of all processes; it’s the first program the kernel starts when booting. init , which can be found in /sbin/init, is responsible for getting the system up and running after the kernel has finished booting.

There are three simple utilities to manage your startup or init scripts

Full Story.