[geeks] Need expert opinion

Sandwich Maker adh at an.bradford.ma.us
Tue Oct 5 11:29:20 CDT 2004


" From: velociraptor <velociraptor at gmail.com>
" 
" On Mon, 4 Oct 2004 11:41:33 -0400 (EDT), Sandwich Maker
" <adh at an.bradford.ma.us> wrote:
" > " From: velociraptor <velociraptor at gmail.com>
" > "
" > " Anyone have any idea what might happen if two processes tried to
" > " HUP the same pid at the same time?
" > 
" > depends on whether the receiving proc resets its sighandler fast
" > enough to properly catch the second hup.  you'll either get the
" > intended response or [i think] termination.
" > 
" > " I had a situation where two scheduled cron processes were trying to
" > " HUP the same httpd when rolling the logs.  The cron entries were
" > " for the same times.  :-/
" > 
" > oopsie...
" 
" Hmmm...this is Solaris.  I was speculating on the cause of a
" huge decrease in traffic (24K hits/day to 4K hits/day across 4
" servers), but neither of those results would explain it.  If the 
" httpd died, a) the load balancers would ship it to the other 
" servers, and b) our alarm would go off.  Even if "b" failed, "a"
" would still happen.

the way i'd write it, i'd set the sighandler to drop further hups
while processing a hup, then reset it to catch them when finished.
that wouldn't necessarily solve your double-hup problem though.  you
might end up rolling the logs -twice-, in quick succession.  a 'guard
zone' of even a second would go a long way to fixing it.

" []
" [0] Generally, I don't mind dealing with clients--it can be a 
" refreshing reminder that you are doing something that helps
" someone on the other end--but these guys...oooo, boy.

clients -are- the ultimate purpose of our professional lives...
________________________________________________________________________
Andrew Hay                                  the genius nature
internet rambler                            is to see what all have seen
adh at an.bradford.ma.us                       and think what none thought



More information about the geeks mailing list