RE: [squid-users] Squid Memory always increasing

From: Saurabh Agarwal <Saurabh.Agarwal_at_citrix.com>
Date: Mon, 28 Feb 2011 23:37:14 +0530

Thank You Amos. This was helpful. I went through wiki page related to Squid memory usage which helped me understand more about Squid Memory usage. Thanks!

Regards,
Saurabh

-----Original Message-----
From: Amos Jeffries [mailto:squid3_at_treenet.co.nz]
Sent: Sunday, February 27, 2011 10:10 AM
To: squid-users_at_squid-cache.org
Subject: Re: [squid-users] Squid Memory always increasing

On 26/02/11 16:06, Saurabh Agarwal wrote:
> Thanks Amos! One more question.
>
> When there is no load on Squid after a period of heavy load will Squid memory footprint won't go down? I think it should. Are there some ways other than "memory_pools off" config to make Squid free the earlier malloc'ed memory.
>

Squid should always be "freeing" memory as soon as it is finished with.
Allocating and freeing is not to be confused with the memory footprint,
which always can only grow.

Squid allocates from the OS as much as needed. More when more is needed.

When pools are on Squid will retain internal pools to locate the
currently available/"free" memory tuned to exact object sizes Squid uses
for re-use by the objects in later needs. With pools turned off in Squid
this is returned for the OS to maintain such pools via its less well
tuned algorithms.
The OS will still report a memory footprint equal to the largest *ever*
allocated amount used by Squid. Which should grow to a max and hold there.

The wiki page on memory usage explains what Squid uses RAM for. To give
you a good idea whether the amount is reasonable for your Squids maximum
traffic load. And to allow you to roughly budget the system RAM.

Amos

-- 
Please be using
   Current Stable Squid 2.7.STABLE9 or 3.1.11
   Beta testers wanted for 3.2.0.5
Received on Mon Feb 28 2011 - 18:07:35 MST

This archive was generated by hypermail 2.2.0 : Tue Mar 01 2011 - 12:00:05 MST