OK to change avg_obj_size with same L1/L2 config?

From: Steve Snyder <swsnyder@dont-contact.us>
Date: Mon, 20 Dec 1999 18:54:47 -0500 (EST)

After running Squid (v2.2S5) for over a month, my average object size
(as reported by cachemgr.cgi) is 8.5KB. This is in contrast to the
default size of 13KB.

This is my current config (1st 2 params are default):

    store_avg_object_size 13 KB
    store_objects_per_bucket 50
    cache_mem 16 MB
    cache_dir /var/spool/squid 512 2 254

By my calculations, I can reduce the configured average_object_size
down to 9KB without changing my existing L1/L2 configuration. The
limits for L1=2, L2=254:

     L1 = (cache_size * 1024 * 2 / avg_obj_size / L2 / L2)
    1.01 = (512 * 1024 * 2 / 16 / 254 / 254)
    1.25 = (512 * 1024 * 2 / 13 / 254 / 254)
    1.80 = (512 * 1024 * 2 / 09 / 254 / 254)

My interest in reducing the default avg_obj_size is to bring Squid's
assumptions in line with the real world. This brings up 2 questions:

1. Having built up over a month's worth of cached objects, would I be
hurting something by reducing the avg_obj_size and leaving the disk
structure un touched? (The alternative is to wipe the cache and start
clean with the new size assumption.)

2. If I modify the default store_avg_object_size parameter, is it
necessary/advisable to also modify the default
store_objects_per_bucket parameter? They look like they are related,
but I'm not clear on this.

Thank you.

*** Steve Snyder ***
Received on Mon Dec 20 1999 - 22:31:33 MST

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