On Tue, Apr 15, 2008 at 5:03 PM, John Gateley <[EMAIL PROTECTED]> wrote:
>  if($UseLog) {
>   Sys::Syslog::setlogsock('unix');
>   openlog("$WebScriptName", 'pid', 'daemon');
>   syslog('info', "$WebScriptName starting");
>  }
>  ...
>  syslog('info', "Message"); # Actually buried in a subroutine
>  ...
>
>  Originally, if $UseLog was false for an invocation of the script,
>  the "Message" would not appear in the syslog.
>
>  When I turned on mod_perl, sometimes I found "Message" appearing,
>  but under a different script's name.
>
>  So: mod_perl is somehow saving the socket state between runs of
>  webscripts, right?

The perl interpreter stays around, so yes, a socket opened will stay
open until you close it.  That may or not be the problem.  I'd suggest
you try closing it at the end of each request (maybe with a cleanup
handler) and see if that makes the problem go away.

- Perrin

Reply via email to