Originally Posted by nagavinodh
what is rc.d in etc?what things contains rc.d?
It contains the list of all services/daemons, means, which service will start in which runlevel and which service will stop in which run levels and the script to perform these actions.
suppose a service/daemon let smartd(Hard drive health monitor service)in different runlevel dirs in /etc/rc.d/,as follows
rc0.d - K01smartd -> ../init.d/smartd
rc1.d - K01smartd -> ../init.d/smartd
rc2.d - S99smartd -> ../init.d/smartd
rc3.d - S99smartd -> ../init.d/smartd
rc4.d - S99smartd -> ../init.d/smartd
rc5.d - S99smartd -> ../init.d/smartd
rc6.d - K01smartd -> ../init.d/smartd
1.prefix with 'K' means the service will be killed in the corresponding runlevel
2.prefix with 'S' means the service will be started in the corresponding runlevel
The number after K and S are the serial no in order of which the service will be started or stopped.
Actually all the services/daemons are stored in /etc/rc.d/init.d and '->' means they are the symbolic link to the services.
rc.local- Its a script to launch the programmes outside runlevels
rc.sysinit- It's the script that does the system initialization tasks that are consulted with each runlevels..
So after getting knowledge on all this u can desgin ur own runlevel.