Re: [squid-users] Squid Under High Load

From: Adrian Chadd <adrian@dont-contact.us>
Date: Wed, 7 Feb 2007 17:01:27 +0800

On Wed, Feb 07, 2007, Manoj Rajkarnikar wrote:
> On Tue, 6 Feb 2007, Matus UHLAR - fantomas wrote:
>
> > On 04.02.07 13:57, Adrian Chadd wrote:
> > > You already can, to some extent. See the cache_dir configuration
> > > information; there's a "max object" size parameter. cache_dirs are checked
> > > in order so just have your small object stores have a max objsize
> > > parameter of something other than -1.
> >
> > however, having option min-size would also be nice, to be ablke to configure
> > cache_dirs even more.
>
> Yes and would give even more granular control. one more question, how and
> when does the squid determine the size of the object it fetches ?? (some
> sort of header?? or after the object has been downloaded??)

Squid can be told via a HTTP header (Content-Length) or just by keeping track of
how much data is read off the network.

Trouble is, a lot of potentially cachable small objects may not have a Content
Length header for some reason, so Squid has to read until the socket returns
end-of-file (and therefore persistent connections can't be supported.) Chunked
TE works around this a little (allowing scripts and such to be inside a persistent
connection but not have the size up-front), but I digress.

In any case, its not that difficult to do and I'll be adding that functionality
as an explicit feature in the storage manager rewrite I'm doing. Its kind of needed
to implement an efficient small-object store. It'll get there, it'll just take
time. :)

Adrian
Received on Wed Feb 07 2007 - 01:57:18 MST

This archive was generated by hypermail pre-2.1.9 : Thu Mar 01 2007 - 12:00:01 MST