Prevent varnish from deleting its entire cache(obj.lastuse)

Fredrik Kristiansen fredrik at
Tue Jan 15 23:34:32 CET 2008


I'm trying to prevent varnish from deleting its entire cache when full, so I
have added this to our VCL confguration:

sub vcl_discard {
    # Keep objects in use last 5 minutes
    if (obj.lastuse > 300) {


But variable obj.lastuse don't seem to be available and varnish won't start
with this script.

Fredrik Kristiansen <>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the varnish-misc mailing list