Daemontools is a software suite for Unix that makes it easy to run any program or script as a daemon.
I recently ran into an interesting problem with daemontools - none of the STDOUT output from my daemon was showing up in the log file.
It turns out that your daemon must use unbuffered STDOUT or it won't go into the log file. In my case the daemon is a Perl script so I added automatic flushing of output buffers to the script, and it works. That means I added this:
to the Perl script.