Re: Large object wants to eat all memory

From: Adrian Chadd <adrian@dont-contact.us>
Date: Sun, 24 Mar 2002 08:46:20 -0700

On Sun, Mar 24, 2002, Vladimir B. Savkin wrote:
> Hi,
>
> sometimes Squid keeps very large objects (larger than maxObjectSize)
> completely in memory until last client finishes downloading.
> I see this on 2.5 and 2.6 pre-commloops. It causes thrashing and
> big performance hit when all RAM is depleted.
>
> Debugging shows that storeSwapOut is the offending function.
> Bad thing happens when storeSwapOutAble(e) returns true and
> storeCheckCachable(e) returns false (because object is too big).
> In this case mem->inmem_lo stays at 0 and swapout never starts
> (this happens when Content-Length field is present in headers).
>

Oh?

storeSwapOutAble() shouldn't return true in this case IMHO -
if the object is too big, we want to free up memory when a
client has finished with it.

Let me take a look at it. This will definitely be fixed
in squid-HEAD soon (since my next round of commloops removes
all of this memory magic) but I"ll come up with a patch for
squid-2.5 before it is released.

Thanks!

Adrian
Received on Sun Mar 24 2002 - 08:46:21 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:14:53 MST