Re: [squid-users] If not modified since is causing near-hits

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Tue, 04 May 2010 04:42:16 +0000

On Mon, 3 May 2010 13:28:21 -0700, David Raccah <raccah_at_gmail.com> wrote:
> Hello,
>
> Please excuse the newbie. I checked most of the search engines on
> squid pages and could not find what I was looking for. Though it may
> be because I did not use the correct keywords.
>
> So we have a large set of squid boxes sitting in front of some slow
> running code. The data is mostly static, so we use squid as a proxy
> and it caches the data. The TTL on the cache for now is 1 week or
> more, and so we are saving the backend/origin from being pounded and
> love it!!! However, we are seeing a large number of near-hit instead
> of pure hits. For us a near-hit is equal to a miss, because it caches
> the cache (L1 and L2) to go to the origin/backend. We are using HTCP
> to clear the cache when there is a change (much like wikipedia does),
> so we can trust that our L2 is as close to fresh as possible.
>
> So:
>
> 1) Since we can guarantee that the L2 will have the latest
> information, is there a way to ignore the "if-not-modified" header?
>

Depends on where it is being generated and exactly which if the If-*
header it is.
(there is no if-not-modified header).

> 2) is there a way to declare the L2 cache as the origin-server instead
> of just a parent cache - not a great approach, but need to mitigate
> going to the origin if the L2 has a hit?

Yes. Setting "originserver" on the parent cache_peer.
However I think ICP/HTCP are not sent to origin servers.

>
> 3) is there a utility to update the timestamp of the cached objects.

Maybe the squidpurge tool. I have not yet looked at it closely.

Amos
Received on Tue May 04 2010 - 04:42:20 MDT

This archive was generated by hypermail 2.2.0 : Tue May 04 2010 - 12:00:03 MDT