httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <>
Subject Re: Keep it simple
Date Tue, 19 Aug 1997 21:38:33 GMT
One little warning here... as documented in stopping.html, log file
rotation and SIGUSR1 aren't friendly with each other.  Since there still
exist children that have the log open, and a rotator has no way to know
when they're done.  I use a 20 minute delay in my USR1 rotation scripts. 

Two ways around this include reliable piped logs, and log file locking. 
The latter is pretty easy to implement -- all log files are flock()d in
shared mode.  The log rotator tries to lock exclusive.  It'll get the lock
when all the old children have exited.  If someone wants to implement
this, go for it. 


On Tue, 19 Aug 1997, Brian Behlendorf wrote:

> Regarding enhancing custom logging to do a bunch of conditional things,
> named formats, replacements for mod_log_agent/referrer, etc:
> I very strongly feel that this is a slippery slope for us to be walking
> upon; that everything proposed here can be done completely *outside* the
> web server software, with a perl script or even a separate binary program
> we release.  Its inclusion in Apache will add code, directives, promises of
> future support, and complexity, with not much gain over using a separate
> process.  Dean's desire to see reliable piping to logging scripts is in
> line with this, so that's cool, but I am very tempted to give a -1 to the
> various other proposals.  
> Now that we have a fairly robust graceful restart system, rotating web logs
> and running a perl script on them every day, hour, even 10 minutes is no
> big deal.  What more do we have to gain by putting that logic directly in
> Apache?  Let's write a really nice perl script and distribute that with
> Apache.
> Note that I am also in favor of efforts to formalize the error logging.
> 	Brian
> --=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=--
> "Why not?" - TL  - -

View raw message