Re: [squid-users] Responses to squidclient and browser are different

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Sat, 07 Dec 2013 14:23:51 +1300

On 7/12/2013 12:10 p.m., mangpo wrote:
> I config the squid cache such that it caches pretty much everything and
> pretends those pages are fresh for a long time.

This is a Very Bad Idea, but your problem happens regardless of what you
configure so I will skip that for now...

<snip>

> refresh_pattern ^http: 600000 100% 700000 override-expire override-lastmod
> reload-into-ims ignore-reload ignore-no-cache ignore-private ignore-no-store
> ignore-must-revalidate ignore-auth
>

<snip>

> However, when I tried to load http://techcrunch.com, I did not get the same
> stale page that I got when using squidclient. The browser always gave me a
> real fresh page.
>
> Why is it doing that? How can I make the browser respond with content in the
> cache? Please help!

Because "Vary:Cookie" the object returned for that URL changes depending
on content encoded inside the Cookie headers.

Cookie is so large and changes so easily that there are nearly an
infinite number of objects cached for that one URL. HIT'ing on a
previously cached copy is highly unlikely.

Amos
Received on Sat Dec 07 2013 - 01:23:58 MST

This archive was generated by hypermail 2.2.0 : Sat Dec 07 2013 - 12:00:04 MST