Re: [squid-users] Howto Clear Cache Periodicaly

From: Henrik Nordstrom <henrik@dont-contact.us>
Date: Tue, 11 Apr 2006 22:13:18 +0200

tis 2006-04-11 klockan 08:31 -0400 skrev Guillaume Vachon:

> I have a squid that has been caching for like 10 month. It now have an
> amazing size of 4.5 gig. When browsing on the web, it is now very very
> slow. I restarted squid with a clean cache. Everything was fine again.

This is usually a tell-sign that you have run out o memory. There is a
couple of other conditions which could cause this as well, but excessive
memory usage is by far the most common. As already indicated the FAQ has
good guidance about how much memory Squid uses, in fact a whole chapter
about this subject alone.. it is a often misunderstood aspect of Squid.

Some of the other common causes to significant slowdown when cache is
populated is

  - Request load on the borderline of what the harddrive(s) can handle.
A full cache requires more I/O than an empty cache as removing content
from the cache also costs I/O..

  - slocate updatedb or other cronjobs trying to index the cache files
in vein..

Collecting system statistics with sar or similar tools is a good step to
have the required information available to be able to analyze why a
system has become slow.

It is also worth noting that it isn't uncommon that a freshly restarted
Squid runs faster for a while (several minutes) as it takes some time
before the client request load is back. By restarting Squid you
terminate all currently pending requests, often including large long
running downloads..

Regards
Henrik

Received on Tue Apr 11 2006 - 14:13:29 MDT

This archive was generated by hypermail pre-2.1.9 : Mon May 01 2006 - 12:00:02 MDT