[squid-users] Squid 3.1.6, fails to cache static content

From: J4K <junk4_at_klunky.co.uk>
Date: Thu, 04 Aug 2011 17:24:15 +0200

Hi there,

    Quick basic config question on a different server I have had to
set-up. The server refuses to cache any items. Static test page
(3751bytes) always give a cache MISS. I am unsure what I missed ;(
Apologies for a such a simple configuration question.

Squid Cache: Version 3.1.6

http_port 11.11.11.11:3128
auth_param basic program /usr/lib/squid3/ncsa_auth /etc/squid3/squid_passwd
icp_port 0
htcp_port 0
snmp_port 0
acl manager proto cache_object
acl localhost src 127.0.0.1/32 ::1
acl to_localhost dst 127.0.0.0/8 0.0.0.0/32 ::1
acl SSL_ports port 443
acl SSL_ports port 8443
acl Safe_ports port 80 # http
acl Safe_ports port 3100 # http Tatsoft
acl Safe_ports port 21 # ftp
acl Safe_ports port 443 # https
acl Safe_ports port 70 # gopher
acl Safe_ports port 210 # wais
acl Safe_ports port 1025-65535 # unregistered ports
acl Safe_ports port 488 # gss-http
acl Safe_ports port 591 # filemaker
acl Safe_ports port 777 # multiling http
acl CONNECT method CONNECT
acl ncsa_users proxy_auth REQUIRED
acl localnet src 10.0.0.0/8 # RFC1918 possible internal network
acl localnet src 172.16.0.0/12 # RFC1918 possible internal network
acl localnet src 192.168.0.0/16 # RFC1918 possible internal network
acl localnet src fc00::/7 # RFC 4193 local private network range
acl localnet src fe80::/10 # RFC 4291 link-local (directly plugged)
machines

icp_access deny all
htcp_access deny all
snmp_access deny all

http_access allow manager localhost
http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow localhost
http_access allow ncsa_users
http_access deny localnet
http_access deny all
hierarchy_stoplist cgi-bin ?
coredump_dir /var/spool/squid3
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
refresh_pattern . 0 20% 4320
cache_peer localhost parent 8118 0 default no-query no-digest
no-netdb-exchange
cache_dir aufs /var/cache/squid3 384 16 256
maximum_object_size 512 KB
never_direct allow all

access.log:
1312470370.224 18 83.123.123.123 TCP_MISS/304 259 GET
http://www.example.co.uk/ testuser DEFAULT_PARENT/localhost -
1312470373.292 5 83.123.123.123 TCP_MISS/304 259 GET
http://www.example.co.uk/ testuser DEFAULT_PARENT/localhost -
1312470375.393 6 83.123.123.123 TCP_MISS/304 259 GET
http://www.example.co.uk/ testuser DEFAULT_PARENT/localhost -
1312470377.442 5 83.123.123.123 TCP_MISS/304 259 GET
http://www.example.co.uk/ testuser DEFAULT_PARENT/localhost -
1312470379.243 5 83.123.123.123 TCP_MISS/304 259 GET
http://www.example.co.uk/ testuser DEFAULT_PARENT/localhost

I presume that it is a problem with the cache_peer directive, but this
should make sense to me if the proxy-only option was there, but its not.

The cache is setup and initialised (I did this with the squid3 -z option).

Regards.
Received on Thu Aug 04 2011 - 15:24:02 MDT

This archive was generated by hypermail 2.2.0 : Thu Aug 04 2011 - 12:00:01 MDT