From: <wi...@da...> - 2003-01-28 21:50:45
|
Hey all, While developing an application I am hoping to use the Proc::Daemon::Init module along with Log4perl, but it seems whenever I use Proc::Daemon's Init function the log4perl logger does not work, I am assuming because I am calling 'init' before Proc::Daemon has done its thing, and in particular because of #6 below. Is my hunch correct? Will there be a problem with not having a controlling terminal (can't see a reason for it, except in the case of trying to use a Log::Dispatch::Screen appender, or the like). >From the Proc::Daemon docs: "The Proc::Daemon::Init function does the following: 1. Forks a child and exits the parent process. 2. Becomes a session leader (which detaches the program from the controlling terminal). 3. Forks another child process and exits first child. This prevents the potential of acquiring a controlling terminal. 4. Changes the current working directory to "/". 5. Clears the file creation mask. 6. Closes all open file descriptors. " Thanks for your insights or suggestions on a better way to handle any of this, http://danconia.org |