[squid-users] squid cache

Amos Jeffries squid3 at treenet.co.nz
Thu Oct 1 00:10:32 UTC 2015

On 1/10/2015 8:41 a.m., Leonardo Rodrigues wrote:
> Em 30/09/15 16:35, Magic Link escreveu:
>> Hi,
>> i configure squid to use cache. It seems to work because when i did a
>> try with a software's download, the second download is TCP_HIT in the
>> access.log.
>> The question i have is : why the majority of requests can't be cached
>> (i have a lot of tcp_miss/200) ? i found that dynamic content is not
>> cached but i don't understand.very well.
>     That's the way internet works ... most of the traffic is dinamically
> generated, which in default squid configurations avoid the content to be
> cached.

That has not been true since Squid-3.1. Squid which are HTTP/1.1 enabled
can and do cache dynamic content quite easily.

> Nowadays, with the 'everything https' taking place, HTTPS is
> also non-cacheable (in default configurations).
>     And by default configurations, you must understand that they are the
> 'SECURE' configuration. Tweaking with refresh_pattern is usually not
> recommended except in some specific cases in which you're completly
> clear that you're violating the HTTP protocol and can have problems with
> that.

That depends on what is being tweaked. The options and values that are
marked as violation are so, the others are safe to be adjusted if you
need them.

>     In short, the days of 20-30% byte-hits are gone and will never came
> back anymore.

Yeah we cache so much *more* than 30% nowdays.
Of course ones log analyzer has to notice that the transactions logged
as REFRESH are also cached objects, not only the ones labelled HIT.

>     Keep your default (and secure) squid configuration, there's no need
> to tweak refresh_pattern unless on very specific situations that you
> clearly understand what you're doing.


More information about the squid-users mailing list