Re: [squid-users] configuration for BYTE hit ratio

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Tue, 30 Jun 2009 14:03:15 +1200

On Mon, 29 Jun 2009 11:36:21 -0300, Leonardo Rodrigues
<leolistas_at_solutti.com.br> wrote:
> what would be the parameters that i should change for getting a
> great BYTE hit ratio in squid ???? I was thinking of only caching files
> bigger than 1Mb and lower than 20Mb, let's say ....
>
> what parameters should i configure to acchieve that ?

Quite the opposite I would have thought.

For BYTE HITs you want to be caching _everything_, so no limits on object
size. The vast majority of objects will still be in the 0-512KB range
somewhere so cutting them out of cache will hurt both ratios. Storing very
large files only hurts the REQUEST HIT ratio, since one large object may
push out many little objects. Same BYTE equivalence though.

Almost needs not be said that the more disk space + RAM-cache you can use
for the cache the more bytes you can store, and the more additional RAM
needed to index it.

Also, reducing the cache_mem RAM cache size trades the speed of those few
objects for an order of magnitude or two more disk cache. So the trade-off
may be worth it. You will have to decide.

Then there are the refresh_pattern settings. That allows you to increase
the minimum storage times for things which will increase the chance of a
HIT occuring on them.

I'm not too clued up on the storage garbage collection algorithms, but I
would expect LRU (least recently used) to probably be the best replacement
policy for this usage.

Amos
Received on Tue Jun 30 2009 - 02:03:22 MDT

This archive was generated by hypermail 2.2.0 : Tue Jun 30 2009 - 12:00:04 MDT