Gerrit Pape wrote on 31/07/2005 19:17: > You might be interested in this web page > > http://homepages.tesco.net/~J.deBoynePollard/FGA/unix-daemon-design-mistakes-to-avoid.html
ARG. Not that page again. (OK, I'm exaggerating.) Granted, it does mention a few good things, but also makes various mistakes itself IMHO: Most importantly, it discourages use of syslog. Even with all its disadvantages, I definately prefer daemons using syslog over any other mechanism mostly because I (as the admin) can easily redirect the log to remote hosts, log different parts of the information to different logs (like log everything above debug to a file only kept for 24h while logging everything from warn upwards to some file kept for a month). With modern syslog implementations like syslog-ng I am able to divide or merge logs from different programs or syslog facilities as I want. I wouldn't be able to do so with daemons which always log to stdout/stderr. The other advices are good to keep in mind though they do have flaws themself because they don't even mention the downsides of the approach they are recommending. One example is the don't background advice. A daemon should allow some mechanism to put it in the background and detach with its filedescriptors (especially STDIN/STDOUT/STDERR) closed, so that the shell which started it can exit cleanly. cu, sven
signature.asc
Description: OpenPGP digital signature
_______________________________________________ initscripts-ng-devel mailing list [email protected] http://lists.alioth.debian.org/mailman/listinfo/initscripts-ng-devel

