Python daemon

Steve Holden sholden at holdenweb.com
Tue Jun 25 11:02:15 EDT 2002


"Cameron Laird" <claird at starbase.neosoft.com> wrote ...
> In article <mailman.1024999953.15765.python-list at python.org>,
> Roman Suzi  <rnd at onego.ru> wrote:
> .
> .
> .
> >> 3. restarting of the program if it fails, or the watchdog doesn't
trigg=
> >er
> >
> >Run the program from the /etc/inittab - if it terminates,=20
> >init will restart it for you.
> .
> .
> .
> This is one of the great FMMs under Unix--the under-utilization
> of init(1).  From everything I know, Roman's exactly right, that
> /etc/inittab is the right way to set up a process that you truly
> want to keep running.  However, many, MANY Unix hosts have all
> kinds of ugly home-brewed hacks to duplicate this functionality.
> I don't have an explanation, beyond the rather tautologous ob-
> servation that init(1) simply isn't as widely understood as it
> deserves to be.


You're probably right. Don't forget you need to specify "respawn" to have
the process restarted when it terminates.

Of course, this doesn't address the issue of if the controlled process stops
making progress but doesn't die.

regards
-----------------------------------------------------------------------
Steve Holden                                 http://www.holdenweb.com/
Python Web Programming                http://pydish.holdenweb.com/pwp/
-----------------------------------------------------------------------








More information about the Python-list mailing list