Search squid archive

Re: Configure accelerator mode to serve from cache when source server not available

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Squid Users:
>
> I am trying to determine which set of timeout-related configuration
> options would result in the following behavior:
>
> We currently use a squid proxy as an HTTP accelerator for serving
> graphical charts. The hostname 'charts.altosresearch.com' resolves to an
> IP address/port on which squid (v3.0) is running. The 'defaultsite'
> option is set to 'www.altosresearch.com', which actually generates the
> graphical charts. All of this works very well:
>
> http://charts.altosresearch.com/AltosCharts/CA/SAN+FRANCISCO/94115/median_price/a/1,2,3,4/m/e/mf/552.png
>
>
> However, there are times when in production we have to take the
> apache/tomcat server at 'www.altosresearch.com' offline for maintenance.
> During these times, any requests to 'charts.altosresearch.com' will fail
> because the squid proxy's attempt to validate the cached version fails.

You appear to be mistaking the purpose of 'defaultsite'.

The only 'defaultsite' in squid is in the http(s)_port settings.
There it means the Host: header name to use if the client does not specify
one. Nothing more.

>
> Instead, I would like to configure squid to observe the following rule:
> If the connection to www.altosresearch.com fails (returns 400/500 code,
> or connection times out after XX seconds), then attempt to serve the
> response using a cached object. The configuration variable
> 'minimum_expiry_time' seems related, but not sufficient.

Then you want to try the Squid 2.7 development release and add some
cache-control headers to your servers output.
http://plone.org/products/cachefu/roadmap/9
http://www.squid-cache.org/Versions/v2/2.7/

Amos



[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux