[HPADM] closed runlevel question
- From: "BAKHSHESH Kazem" <BAKHSHEK@xxxxxxxxxx>
- Date: Wed, 3 Jun 2009 20:28:27 +0200
Thanks you very much for your help specially James J.Perry, Ford Phillip, dave.johnson,
Elf Hartmen and Bill Hassell and others.
Kazem Bakhshesh(Administrateur Système : HP-UX)
E-Mail : bakhshek@xxxxxxxxxx
Tel : 01.72.94.73.09
If I want to create a service which start/stop on rc3.d
who can I find the safe order number
for exemple K???service
if my initdefault is 3 in /etc/inittab (init:3:initdefault: )
/sbin/rc3.d/K999service would be executed when serveur is
To do start / stop scripts, I use the following process:
* Indentify the run level where I want the process to start and at what part of that run level startup I want it to run.
An Apache webserver that connects to a database to query some critical data. The database starts in run level 3 with job numeric ID
65 (S65databae). So this instance of Apache needs to start after S65database so I will normally pick a unique number after that point, say 66. Thus I create a symbolic link from /etc/init.d/apache to /etc/rc3.d/S66apache.
* Kill scripts numbering is the inverse of the start script numbering to make the scripts shut down in the proper order when starting from 1 just as with the start scripts.
Using the above Apache example I subtract 66 from 100 to get 44 and then I link /etc/init.d/apache to /etc/rc2.d/K44apache. The kill script for the database in this example would be /etc/rc2.d/K45database.
The way the process works when going from runlevel 3 to runlevel 2 is that the OS is told that it needs to run the stop/kill scripts starting at K01 and got through them numerically.
- Prev by Date: [HPADM] Re: runlevel question
- Next by Date: [HPADM] closed runlevel question
- Previous by thread: [HPADM] runlevel question
- Next by thread: [HPADM] closed runlevel question