Re: Dead Horse

From: Dancer <dancer@dont-contact.us>
Date: Tue, 19 May 1998 11:09:57 +1000

--MimeMultipartBoundary
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Chris Wedgwood wrote:
>
> > > Oh, to further confuse this and make me think this might be a libc
> > > problem, another cache under test, only this time running with a
> > > different libc doesn't appear to be growing abnormally (yet).
> >
> > Hm.. Well, this would be the easiest answer for Squid :) Let us know if
> > the problem re-appears with the other libc.
>
> Can anyone explain to me the meaning of the various parts of the memory
> pools stuff and how it relates to the cache_mem settings? (if at all)
>
> I was under the impression that cache_mem would specific an upper bound for
> the amount of memory the squid should use, but apparently this isn't the
> case.
>
> Looking at the source its not really clear to me what exactly is going on
> there.
>
> With cache_mem at 16MB, I have 34MB allocated, 32MB in use an 3MB idle. Is
> there some way I can cap this form going too high?
>
> At the present rate this will start swapping in a day or so and presumably
> performance will really suck then....

Okay: The amount of memory squid uses is roughly like this (IIRC):

squid itself: ~1.2MB (general accounting and whatnot. Overheads)
hot-cache: setting of cache_mem (this is the memory cache)
ipcache & fqdncache: depends on settings (for caching dns lookups)
cache index: 100 bytes per object currently present in the disk-cache or
hot-cache.
transit buffers: Equal to the combined stored sizes of the maximum
concurrently fetched objects since startup. (This is an overhead. Your
users determine this by the number and size of objects that get fetched
concurrently)

On the plus side, I've had some recent success by linking dlmalloc to
squid 1.1. Under linux it is capable of releasing memory back to the
operating system pool....something which almost no other malloc
implementations perform. I've set it up, and it holds it's own. No code
changes, just a Makefile alteration.

D

--MimeMultipartBoundary--
Received on Tue Jul 29 2003 - 13:15:49 MDT

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