Re: [squid-users] New Accel Reverse Proxy Cache is not caching everything... how to force?

From: Waitman Gobble <waitman_at_waitman.net>
Date: Thu, 30 Jul 2009 22:04:30 -0700

Amos Jeffries wrote:
> Andres Salazar wrote:
>> Hello,
>>
>> Ive setup my first reverse proxy to accelerate a site, ive used wget
>> to spider the entire site several times and noticed that even after
>> running it some files never get cached like html files! I presume it
>> is because the htmls dont have the correct cache headers.
>>
>> It didnt even want to cache up .swf files, but then I added this line
>> and it helped a lot but not completely.
>>
>> refresh_pattern . 0 20% 4320 ignore-reload
>>
>> Iam thinking then the best approach is to make squid cache EVERYTHING,
>> and then manually give it specific exceptions of dynamic content (
>> like .php and some .html with embedded php scripts). I dont want to
>> start editting files because I want to test the performance increase
>> before adding headers one by one.
>
> No its not the best approach. The best approach is to take what really
> exists right now and see how the variations you plan change things.
>

hi andres,

one question, you DID increase the defaults in squid.conf right?
I *think* the default maximum_object_size is 8k and cache_mem is 32M and
most "examples" i've seen on the 'net set the cache_dir to 100 or 256 M
(but please check the docs for the version you're running, as these
values change). If you run like that it won't cache much of anything, at
least from what I've noticed. I cranked up the numbers and the hit rate
increased significantly within a few hours (18% to 49% at this moment).
I'm not an expert with regards to 'sane and appropriate' settings but my
current experiment is

cache_dir ufs /cache 307200 16 256
maximum_object_size 65536 KB
cache_mem 3008 MB

seems to be working properly, at the moment. squid is kind-of a living
thing though, i'll see what happens over the next few days. :-)

Maximum Size: 314572800 KB
Current Size: 1182386 KB
Percent Used: 0.38%
Filemap bits in use: 32249 of 32768 (98%)
Filesystem Space in use: 3098264/465070216 KB (1%)
Filesystem Inodes in use: 117389/60128254 (0%)

HTTP: 256056 Requests, 124443 Hits ( 49%)

i'm slightly concerned about the "filemap bits" but I've read it's
supposed to automagically adjust itself.
I'm still patiently waiting, patiently for that to happen.

waitman
Received on Fri Jul 31 2009 - 05:04:59 MDT

This archive was generated by hypermail 2.2.0 : Fri Jul 31 2009 - 12:00:04 MDT