Search squid archive

Re: forcing retrieval of cached copy

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

 



On Fri, 11 Apr 2008, Henrik Nordstrom wrote:

>ons 2008-04-09 klockan 19:46 +1000 skrev Tim Connors:
>> I played around with squidclient mgr:offline_toggle and refresh_pattern, 
>> but can't convince it not to keep using IMS queries, and/or things like 
>> google (without ? and cgi-bin in the url) that are simply always TCP_MISS.
> 
> You can lony HIT what was allowed to get cached. There is many factors
> which makes a response uncachable. The ? is just a hint..
>
>> Without applying any patches or running a different version, is there a 
>> way to convince it to really and truly ignore all expires, age, etag etc 
>> related headers and if there is a local cache copy at all, do not consult 
>> the web at all, not even for an if-modified-since query?
>
> offline_mode do ignore all expires etc on cached content. But it does
> not override client imposed limits if you use a client which says it
> doesn't accept old content..
>
> > Or perhaps is there a squid commandline query tool, or an option to wget, 
> > curl or lynx that I missed to tell it to tell squid just grab the cached 
> > copy no questions asked?
> 
> cache-control: max-stale
> 
> says the client accepts any cached copy, no matter how old.
> 
> offline_mode enforces this on every request unless overridden by other
> cache-control headers sent by the client.
> 
> 
> > Related of course, is there a tool that shows what is currently in the 
> > cache?
> 
> The purge tool can do that. See the related software section on the web
> page.

In fact, I think squidpurge[1] gets everything in the cache without 
worrying about cache expiry at all.  Thanks for that.

It's got some files (most of the html files have already been purged, 
dissapointingly, given that a whole bunch of very old obsoleted transient 
gifs *have* been cached from a weather site), and I'm just waiting for a 
fellow sysadmin to recover some /var/spool/squid snapshots from the 
backups which *are* working.


[1] http://www.wa.apana.org.au/~dean/squidpurge/  
Just change the Makefile around line 110 to read
ifeq (6,${LIBCVER})
SOCKLEN = socklen_t
endif
because size_t no longer works, and I possibly had to remove 
-march=pentium from OPT_NORM because of a 64 bit issue.

-- 
Tim Connors


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

  Powered by Linux