Hi,
my need is to have Squid caching request to my server like this:
* do NOT bother the server more then once per minute to check if an
update is available
* if the server return a 500, go into timeout or something like this
during an update keep sending the cached resource to the user
Ideally I would like to be able to turn off the server for maintenance
while the Squid frontend keep returning request.
I've been trying to achieve this for a while now without success.
Is this possible?
Can you address me in the right direction?
Thanks.
This is my configuration file (included in the main squid.conf):
Which currently cache updating every minute but start givin error after
that minute if the server is took down.
# http://wiki.squid-cache.org/SquidFaq/ReverseProxy
# http://www.visolve.com/squid/whitepapers/reverseproxy.php
#
http://www.howtoforge.com/how-to-set-up-a-caching-reverse-proxy-with-squid-2.6-on-debian-etch
#
http://www.linuxhomenetworking.com/wiki/index.php/Quick_HOWTO_:_Ch32_:_Controlling_Web_Access_with_Squid
http_port localhost:280 accel ignore-cc defaultsite=localhost
cache_peer localhost parent 8080 0 no-query originserver no-digest
default name=myAccel
refresh_all_ims off
# IP address of web server
#httpd_accel_host 127.0.0.1
# Port of web server
#httpd_accel_port 8080
# Forward uncached requests to single host
#httpd_accel_single_host on
#httpd_accel_with_proxy on
#httpd_accel_uses_host_header off
acl Safe_ports port 280
http_access deny !Safe_ports
acl our_sites dstdomain 127.0.0.1 localhost mobc3.local
http_access allow our_sites
cache_peer_access myAccel allow our_sites
cache_peer_access myAccel deny all
#http_access allow all
#cache_peer_access myAccel allow all
#refresh_pattern /alfresco/service/catalog 0 20% 4320 reload-into-ims
ignore-no-cache refresh-ims ignore-reload
#refresh_pattern /alfresco/service/stream 0 20% 4320 reload-into-ims
ignore-no-cache refresh-ims ignore-reload
# do not cache anything but what I tell you
#refresh_pattern . 0 20% 0
#hierarchy_stoplist .
#never_direct /alfresco/service/catalog
#never_direct /alfresco/service/stream
# cache services
refresh_pattern /alfresco/service/catalog 0 20% 4320
refresh_pattern /alfresco/service/stream 0 20% 4320
refresh_pattern /alfresco/service/news 0 20% 4320
# do not cache everything else
refresh_pattern . 0 20% 0
# see http://wiki.squid-cache.org/KnowledgeBase/DebugSections
#debug_options ALL,3
debug_options 22,3
#debug_options 22,5
Regards,
Daniele Segato