[squid-users] Cacheing the uncachaeable under Windows

From: Alexander Shopov <ash@dont-contact.us>
Date: Sat, 12 Mar 2005 23:07:18 +0200

Hi guys,

I have successfully managed to compile [1] and patch [2] Squid under
Windows with the Cache-Control patch [3]

The reason for this is that I have a buggy web server (or at least the
part that Oracle made - the oc4j handler) that sends Cache-Control
private header with every http request. [4]

I want to fix the effects of the noncachability with squid. I want it to
cache and serve the gifs/js/jpegs/css without contacting the original
server. I want squid to cache all such content and to *not* check the
freshness of objects for at least 12 minutes.

I have entered such lines in squid.conf:

refresh_pattern -i .*\.gif$ 12 100% 12 override-expire override-lastmod
reload-into-ims ignore-reload ignore-no-cache ignore-private ignore-auth

The additional options are due to [3]

I have also deleted the Cache-Control headers with:

header_access Cache-Control deny all

I have increased the maximum size of object in memory:

maximum_object_size_in_memory 50 KB

I have increased debug levels:
debug_options ALL,1 33,2 28,9 22,9

What I have achieved is that access.log shows

1110660668.298 109 127.0.0.1 TCP_REFRESH_HIT/200 488 GET
http://10.10.10.100:7778/pob/images/minus.gif - DIRECT/10.10.10.100
image/gif

While store.log shows:

1110660668.298 RELEASE -1 FFFFFFFF 7BFA02A2F64B44D4A3935AC81EC136F4 304
1110660668 -1 -1 unknown 0/0 GET
http://10.10.10.100:7778/pob/images/minus.gif

The gif image was still not cached (RELEASE -1) and squid still checked
the freshness of the object contacting the web server (TCP_REFRESH_HIT)

The no_cache rule I use is:

acl QUERY urlpath_regex cgi-bin \?
no_cache deny QUERY

What am I doing wrong? After reading the faq, config guide and options
help I still cannot achieve what I want - squid to serve the gifs
instead of the web server for 12 minutes. I cannot use accelerator mode,
because the web server logic breaks.

Best regards:
al_shopov

[1] http://www.squid-cache.org/mail-archive/squid-users/200503/0159.html
[2] http://www.squid-cache.org/mail-archive/squid-users/200503/0028.html
[3] http://www.squid-cache.org/bugs/show_bug.cgi?id=1057
[4] http://download.oracle.com/docs/cd/A97329_03/index.htm
Received on Sat Mar 12 2005 - 14:06:51 MST

This archive was generated by hypermail pre-2.1.9 : Fri Apr 01 2005 - 12:00:02 MST