Since I discovered daemontools, I no longer write code to do all that typical daemonize stuff. All I write is an ordinary "foreground" program. The daemontools take care of the rest: Logging, starting, stopping, restarting, "backgrounding". With daemontools, a simple-and-stupid daemon needs less than 10 lines shell code, including logging, start-stop-restart, and everything. (See also my various daemontools postings listed in afoken)
Alexander
In reply to Re: Problems with forking
by afoken
in thread Problems with forking
by mraspberry
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |