HP-UX HB v13.00 Ch-03 - System Startup

HP-UX Handbook Rev 13.00 Page 4 (of 14)
Chapter 03 System Startup
October 29, 2013
Introduction
The Run/Halt-Script based system startup that is used at HP-UX 10.X and 11.X follows the
OSF/1 industry standard that has been adopted by Sun, SGI, and other vendors. There are four
components involved: Execution Scripts, Configuration Files, Execution Script Links and
Sequencer Script:
Execution Scripts (/sbin/init.d/*)
are located in /sbin/init.d/. They are invoked with either start” or “stop” argument in
order to start or stop the subsystem.
Example: /sbin/init.d/cron
Configuration Files (/etc/rc.config.d/*)
are located in /etc/rc.config.d/ and contain environment variables that are sourced by the
execution scripts and control their behaviour. The naming convention implies that the name
of a configuration file equals the name of the corresponding execution script.
Example: /etc/rc.config.d/cron
Execution Script Links (/sbin/rc#.d/*)
are located in the /sbin/rcn.d directories and are named SNNNscriptname, where NNN is a
sequence number, and scriptname is the name of an Execution script in the /sbin/init.d
directory. Each of these scripts is actually a symbolic link to a run/halt script in
/sbin/init.d. The /sbin/rc script runs them in order by sequence number.
Example: /sbin/rc2.d/S730cron (a.k.a. Start Script Link)
/sbin/rc1.d/K270cron (a.k.a. Kill Script Link)
Sequencer Script (/sbin/rc)
is started from the inittab and invokes each Execution script in the directories /sbin/rc0.d,
/sbin/rc1.d, /sbin/rc2.d, /sbin/rc3.d, and /sbin/rc4.d, in that order. It sources all
the files in the /etc/rc.config.d/ directory.
Log file (/etc/rc.log)
is /etc/rc.log. The log file of the previous system start is /etc/rc.log.old
Sequencer Script
/sbin/rc
/sbin/init.d/cron
/etc/rc.config.d/cron
sources
Start Execution Script Link
/sbin/rc2.d/S730cron
Kill Execution Script Link
/sbin/rc1.d/K270cron
runs
runs
links to
links to