On Mon, Oct 16, 2000, Chemolli Francesco (USI) wrote:
> A problem I've often found (with SQUID-2.4NTLM) is that
> on squid -k shutdown, not always squid shuts down.
>
> Especially when busy, the effect is more likely to be
> a restart, with a dirty swap.state in the process.
>
> Here is a possible explanation on what's happening.
> I haven't checked the code thoroughly, but this
> might be the reason.
>
> When a shutdown-request is received, squid immediately
> closes all service FDs (DNS, authenticators, redirectors,
> everything) BUT it keeps HTTP connections alive to finish
> servicing active request.
> Mix with keep-alive and BAMF! a new request comes in,
> squid tries to DNS-lookup or authenticate and here's a
> shiny new fatal error. Squid dies horribly, and is restarted
> by the parent process.
>
>
> I'm trying to fix it by moving all the Shutdown()
> calls in the main loop save for serverConnectionsClose()
> to SquidShutdown, but this might be a suboptimal solution
> (if it's a solution at all).
>
> Anybody having the same experience?
> Any hints on how to better solve this?
Uhm, lets look at the code ..
Ok, you hav shutting_down defined as a variable. I'm assuming its global
here from the looks of things. How about checking when a new request comes
in if we're shutting down, and if we are issue an ERR_SHUTDOWN?
I always though squid *did* this. :-)
Adrian
-- Adrian Chadd "It was then that I knew that I wouldn't <adrian@creative.net.au> die, as a doctor wouldn't fart in front of a dying boy." -- Angela's AshesReceived on Mon Oct 16 2000 - 09:43:11 MDT
This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:12:43 MST