httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <traw...@attglobal.net>
Subject Re: Do graceful restarts actually work anywhere?
Date Tue, 19 Mar 2002 00:53:11 GMT
"Ryan Bloom" <rbb@covalent.net> writes:

> Just looking through the code and graceful restarts really shouldn't be
> working right now.  The problem is that we pass pconf into the pre_mpm
> phase, but on Unix we only call the pre_mpm phase on graceless shutdown
> or when the server first starts.  We clear the pconf pool on every
> restart, and we register a cleanup with pconf to destroy the scoreboard.
> 
> If I have traced the code correctly, this means that we should be
> deleting the scoreboard on every graceful restart and not re-creating
> it.  I can't see how this is not causing severe seg faults.

Perhaps you missed this line?

  apr_pool_cleanup_kill(pconf, NULL, ap_cleanup_scoreboard);

Graceful restarts for prefork are working properly as far as I can
tell.

Graceful restarts for worker have at least the following problem:

. we potentially leave accepted connections in the queue between the
  listener thread and the worker threads

In neither MPM do we *seem* to have a scoreboard problem.

But something uncool is going on with mod_cgid.  Occasionally today I
was able to end up with two daemons.  I have punted on the cgid issue
while playing with the worker problem mentioned above.  Something
that still bothers me is cgid's lack of a SIGHUP handler.  I'd rather
see the daemon set up a handler for SIGHUP which sets a flag which is
checked in the main cgid loop.  It is (usually) dying now on SIGHUP,
but I wonder if our SIGHUP handler changes based on whether it is
initial startup (MPM didn't get a chance to run yet?) or after a
restart (MPM had registered a SIGHUP handler on the previous
generation which is inherited in the cgid child process).  More
playing required.

-- 
Jeff Trawick | trawick@attglobal.net
Born in Roswell... married an alien...

Mime
View raw message