Customizing system startup in RedHat Linux.
- Oracle Applications: Script to Start and Stop the Application, Database Servers
- Oracle Release 12 – Applications & Database service.
- CentOS Linux install and configure NTP to synchronize the system clock
- Start & Stop 11i Process Details
- Installing Oracle applications 11.5.9 with Redhat 9 Linux system
The default initialization style in RedHat Linux is the SysV style.
BSD style will not be covered in this article.
At boot time, /sbin/init reads instructions from /etc/rc.d/rc.sysinit
first and then goes to one of the /etc/rcN.d directories according to
the specified runlevel in /etc/inittab at the “id:N:initdefault” line.
N is usually 3 or 5, respectively meaning “multiuser startup with full
networking” and “multiuser startup with full networking and XDM (X
display manager) on system console”. Other runlevels are:
0 (shutdown)
1 (single-user mode)
2 (multi-user mode)
4 (user-defined)
6 (reboot)
Next, /sbin/init executes the Kxx scripts first and the Sxx scripts next;
xx stands for a two-digit number that indicates execution order,
starting from lowest to highest. Usually both Kxx and Sxx scripts link
to actual scripts in /etc/rc.d/init.d, though there might be exceptions
such as the one for rc.local (which may be linked to /etc/rc.d/rc.local
as it is for example in RedHat 7.0).
/sbin/init invokes the Kxx scripts with an argument of “stop” and the
Sxx scripts with an argument of “start” (in fact K and S stand for kill
and start), so the convention is to have a subsystem script in init.d
such as ‘nfs’ and links to stop it and start it. For example,
/etc/rc.d/rc0.d/K20nfs stops NFS services on shutdown (level 0) while
/etc/rc.d/rc3.d/S60nfs starts NFS when booting to multiuser mode with
full networking.
It is recommended that you do not add local customizations intermixed
with default startup scripts, so the best thing to do is to add local
stuff (such as starting up an Oracle instance) in /etc/rc.d/rc.local
or in another script with highest numbering, as /etc/rc.d/rc3.d/S99oracle
linked to /etc/rc.d/init.d/oracle. Again, the rc3.d link placement
would be correct if your default runlevel were 3, so remember to
double-check /etc/inittab for the initdefault string !

thanks for your shiarng er342