On Wed, 30 Sep 2009 17:22:34 -0300, Marcus Kool
<marcus.kool_at_urlfilterdb.com> wrote:
> Luis Daniel Lucio Quiroz wrote:
>> Le mercredi 30 septembre 2009 11:14:43, Marcus Kool a écrit :
>>> What are the values for the parameters cache_swap_low and
>>> cache_swap_high ?
>>> For a large cache it is recommended to have them close to each other.
>>> E.g.
>>> cache_swap_low 90
>>> cache_swap_high 91
>>>
>>> You can also add
>>> refresh_pattern (cgi-bin|\?) 0 0% 0
please use:
refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
(the other pattern was tried by the devs and found to catch a few too many
things).
>>> since dynamic pages should not be cached.
>>>
>>> Marcus
>>>
>>> Luis Daniel Lucio Quiroz wrote:
>>>> Hi all,
>>>>
>>>> Well, after implementing cache, in a heavy environment (with about 5k
>>>> users) I'm seeing that our squid is not freeing far enough objects,
our
>>>> 100GB disk cache fills in 5 days. I wonder I misunderstood
>>>> refresh_pattern options.
refresh_pattern is all about *extending* the period for which an object is
cached. increasing the cache size.
It does not assist with reducing things.
>>>>
>>>> I have this:
>>>>
>>>> refresh_pattern -i \.png$ 2880 1% 5760
>>>> refresh_pattern -i \.zip$ 0 1% 1440
>>>> refresh_pattern . 0 20% 4320
>>>>
>>>>
>>>> I wonder to know how would be if I want to keep objects 4 days and in
>>>> 5th
>>>> object could be discarted.
For specific objects you can't. Only the website operator can determine
that kind of fine-grained object control.
>>>>
>>>> TIA
>>>>
>>>> LD
>> cache_swap_low 95
>> cache_swap_high 97
>>
>> is this enoght=?
Maybe yes, maybe no...
check the average object size (squidclient mgr:info or the info page of
cachemgr.cgi). Calculate 2% of your cache_dir size and divide by the avg
object size. This is how may disk erase operations are required of the
CPU+disks when Squid needs to make more space.
>
> If the disk gets full....
> It gets full because there is too little space in the file system
> or the space is reclaimed too slow by Squid.
Because:
* you have set cache_dir size larger than your disks can hold.
* you are logging to the disk where cache_dir resides and logs are filling
up more than their share
* your system and other apps are using the same hard drive as squid
cache_dir and need more space than you left available.
The Q's Marcus asks will lead to your solution...
>
> What is the output of 'df' ?
> What are the values for parameter cache_dir ?
>
> And I recommend to change the parameters:
> cache_swap_low 93
> cache_swap_high 94
>
> -Marcus
Amos
Received on Wed Sep 30 2009 - 22:27:49 MDT
This archive was generated by hypermail 2.2.0 : Thu Oct 01 2009 - 12:00:05 MDT