init script behaviour

Chris Adams cmadams at hiwaay.net
Tue Jun 15 18:40:43 UTC 2010


Once upon a time, Casey Dahlin <cdahlin at redhat.com> said:
> I'd say fire and forget or something close for most sysv initscripts. If
> you want to do better you need a modern tool like systemd/upstart/etc.
> Trying to do it better in bash just makes for piles of ugly, and the
> weird failure modes and corner cases will usually end up being worse
> than the problem.

A well-behaved daemon should be doing all the checking possible before
forking to go into the background.  The init scripts do check the exit
code, so configuration errors, failure to bind to sockets, etc. should
be (and in most cases are) caught that way.

-- 
Chris Adams <cmadams at hiwaay.net>
Systems and Network Administrator - HiWAAY Internet Services
I don't speak for anybody but myself - that's enough trouble.


More information about the devel mailing list