Re: [squid-users] shared-memory cache in Squid3.2 and object size?

From: Amos Jeffries <>
Date: Thu, 02 Aug 2012 18:31:03 +1200

On 2/08/2012 4:11 p.m., Linda W wrote:
> I was looking at logs/code or something and it seemed that if I wanted
> to use
> the multiple processes feature on a multi-core system, they need to
> use shared memory.
> So I setup 8GB for them to share -- verified by looking in /dev/shm
> and seeing an
> 8GB file created by squid each time it starts.
> Ahh.. in the config...this can't be true, can it? 32KB max
> object size?
> (Normally my max object size is 512MB, --- my AVERAGE object size (as
> measured
> by files in my cache at one point, is 37KB -- but that was from 7
> years ago, thought
> maybe 43KB might be closer now, with content inflation...but can't
> really tell...)
> Since It seems squid may be limiting the max shared objects to
> 32KB...which is a
> bit on the tiny side??

Yes, really, and Unfortunately so. 32KB == 1 page allocation for the
particular SMB shared memory systems used.
Using multiple pages per object for shared objects is being worked on,
but is not going to make it into Squid 3.2.

> My system's largest page size is 1GB (Huge page support turned on).
> So why a 32KB limit? That really blows my idea of a fun setup
> --- any benefit gained by as multi-processor squid will be lost on
> losing object sharing...
> Is this still the limit? Is it something that is planned to be
> increased anytime soon?

Hmm. Might be worth checking if those large pages are the same type of
pages SMB uses. We are still limited to one page, but if the page size
itself were changeable the two Alex's might be able to point out what
knob to change.

'twill be attempted as soon as it is possible to do so.

Received on Thu Aug 02 2012 - 06:31:17 MDT

This archive was generated by hypermail 2.2.0 : Sun Aug 05 2012 - 12:00:04 MDT