Operating System - HP-UX
1834137 Members
2379 Online
110064 Solutions
New Discussion

Re: Adding a daemon to a startup script

 
John Booth_1
Advisor

Adding a daemon to a startup script

I have a really simple question, but it is something that has been giving me problems. I need to start a daemon when my 11.0 system starts up. I am not really sure how to do this. Any advice would be helpful.
Thanks in advance,
3 REPLIES 3
harry d brown jr
Honored Contributor

Re: Adding a daemon to a startup script


You'll find general stuff here:

http://www.docs.hp.com/cgi-bin/fsearch/framedisplay?top=/hpux/onlinedocs/B3782-90073/B3782-90073_top.html&con=/hpux/onlinedocs/B3782-90073/00/00/67-con.html&toc=/hpux/onlinedocs/B3782-90073/00/00/67-toc.html&searchterms=hpux%7cstartup%7cscripts&queryid=20011119-055028


What you have to ask yourself, is when do you want this process to start and what dependencies does it have on other software (basically what sequence should it start and when it should be killed for shutwodn purposes).

live free or die
harry
Live Free or Die
Robin Wakefield
Honored Contributor

Re: Adding a daemon to a startup script

Hi John,

Is this a 3rd-party daemon, or one of your own? All standard HP daemons, e.g. inetd, xntpd, start via their respective startup scripts (/sbin/init.d/xntpd for example) by simply running the binary - it should fork, disinherit its parent (close all filehandles, etc.), and continue running happily on its own.

Rgds, Robin.
James R. Ferguson
Acclaimed Contributor

Re: Adding a daemon to a startup script

Hi JOhn:

The most comprehensive paper on this subject can be found here. It is an "easy read" and covers all aspects of startup/shutdown scripts.

While dated for the 10.x release this white paper applies to 10.x *and* 11.x releases:

http://docs.hp.com/hpux/onlinedocs/os/startup.pdf

Regards!

...JRF...