Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've been fighting this for a while, but I can't seem to understand why a request isn't being cached.

Response headers:

HTTP/1.1 200 OK
Date: Tue, 20 Aug 2013 16:42:12 GMT
Server: Apache/2.2.23 (Unix) mod_ssl/2.2.23 OpenSSL/0.9.8e-fips-rhel5 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/ mod_perl/2.0.6 Perl/v5.8.8
Expires: Tue, 20 Aug 2013 22:32:41 GMT
Pragma: public
Cache-Control: max-age=21029, public, must-revalidate, proxy-revalidate
X-Powered-By: W3 Total Cache/0.9.3
Last-Modified: Tue, 20 Aug 2013 16:32:41 GMT
Content-Type: text/html; charset=UTF-8
X-Cache: MISS from proxy
X-Cache-Lookup: MISS from proxy:3128
Transfer-Encoding: chunked
Via: 1.1 proxy (squid/3.2.13)
Connection: keep-alive

The key fields I'm looking at are: Date, Expires, Pragma, Cache-Control, X-Cache, and X-Cache-Lookup

This says to me, "hey, please cache this" but squid just says "MISS" on repeated requests.

The relevant refresh_pattern is:

refresh_pattern . 0 20% 4320 reload-into-ims

What am I missing?

share|improve this question
up vote 3 down vote accepted

Squid had a bug with not caching requests that have the "Vary" header - this question has a detailed description of the issue with some more info, but here's the short version of it :

By analyzing the logs I was able to determine that the hash lookup key used during the store (i.e. the initial request) is different than the one used during the subsequent requests. This is why the subsequent lookups are cache misses.

As of now, the bug is fixed.

share|improve this answer
Looks ood. Thanks. – slm Aug 21 '13 at 1:15

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.