On Fri, 30 Sep 2005, Awie wrote:
> I got a new result by doing test.
>
> Perhaps the question is "Why do I need squid -k shutdown?"
>
> Sometimes, Squid cannot run after system booting (put Squid in rc.local). No
> webcache running checked by netstat -a, but system claims that Squid is
> exist when I try to load Squid (running but not serving). After shutting
> down Squid and load manually, it can run well. The problem (could not
> shutdown Squid) is a trouble.
>
> The result, in both tests (patched and un-patched) Squid can be shutted down
> nicely when the webcache service exist in netstat -a. I think the problem of
> cannot shutdown Squid is only happen in case the problem happen (running but
> not serving). However, Squid 2.5S10 (without patches) can be shutted down in
> any condition.
Ok, this puts things in a completely different picture.
The patch worked just fine, and prevented you from doing something stupid
by giving you a error message.
What has most likely happened above is that there is a stale squid.pid
file left over from before the reboot, and that the old pid registered in
this file has been reused by some other system service when the system
booted.
What you should do to correct this problem is to make sure that any old
pid files is automatically removed on reboot.
If you instead use "squid -k shutdown" it's not Squid which is shut down
but some other system service which happened to get the same pid as Squid
had before the system was rebooted.
You can verify if this is the case by when you see the problem instead of
run "squid -k shutdown" look for the old pid in squid.pid and use ps to
see what process is currently running under that pid. If I am correct you
will find that it is not Squid but some other service.
Regards
Henrik
Received on Fri Sep 30 2005 - 12:44:39 MDT
This archive was generated by hypermail pre-2.1.9 : Sat Oct 01 2005 - 12:00:04 MDT