hi, amos
the squid request header below:
2011/07/21 21:00:44.838| httpSendRequest: FD 14:
GET /test.html HTTP/1.1
Host: test.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; zh-CN; rv:1.9.1.9) Gecko/20100315 Firefox/3.5.9
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: zh-cn,zh;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: GB2312,utf-8;q=0.7,*;q=0.7^M
Via: 1.1 cache.test.com (squid)
X-Forwarded-For: 1.2.3.4
Cache-Control: max-age=18000
Connection: keep-alive
the server response header :
2011/07/21 21:00:44.854| ctx: enter level 0: 'http://test.com/test.html'
2011/07/21 21:00:44.854| processReplyHeader: key 'ACA79E01A135E6ACB25CB2117CC80A71'
2011/07/21 21:00:44.854| init-ing hdr: 0x870e454 owner: 3
2011/07/21 21:00:44.854| parsing hdr: (0x870e454)
Date: Thu, 21 Jul 2011 13:00:44 GMT
Server: Apache
Content-Length: 272
Keep-Alive: timeout=15, max=64
Connection: Keep-Alive
Content-Type: text/html; charset=iso-8859-1
i try squid 2.7 with the same config file (just add acl all ^_^)...
it can work normally and get 404 pages cache hit...
i saw the if (expires==0) expression in the source code.
and i am wondering why the expires should be zero here to get expires update.
void
StoreEntry::negativeCache()
{
debugs(11, 3, "negativeCache: expires:" << expires);
if (expires == 0)
#if HTTP_VIOLATIONS
{
expires = squid_curtime + Config.negativeTtl;
debugs(11, 3, "negativeCache: HTTP_VIOLATIONS: expires:" << expires << " squid_curtime:" << squid_curtime << "C
onfig.negativeTtl:" << Config.negativeTtl);
}
#else
expires = squid_curtime;
#endif
EBIT_SET(flags, ENTRY_NEGCACHED);
}
ssmax
-----------
2011-07-21
Received on Thu Jul 21 2011 - 13:16:25 MDT
This archive was generated by hypermail 2.2.0 : Thu Jul 21 2011 - 12:00:07 MDT