Varnish still 503ing after adding grace to VCL
perbu at varnish-software.com
Tue Mar 8 21:51:55 CET 2011
Hi Drew, list.
On Tue, Mar 8, 2011 at 9:34 PM, Drew Smathers <drew.smathers at gmail.com>wrote:
> Sorry to bump my own thread, but does anyone know of a way to set
> saintmode if a backend is down, vs. up and misbehaving (returning 500,
> Also, I added a backend probe and this indeed caused grace to kick in
> once the probe determined the backend as sick.I think the docs should
> be clarified if this isn't a bug (grace not working without probe):
Check out the trunk version of the docs. Committed some earlier today.
> Finally it's somewhat disconcerting that in the interim between a
> cache expiry and before varnish determines a backend as down (sick) it
> will 503 - so this could affect many clients during that window.
> Ideally, I'd like to successfully service requests if there's an
> object in the cache - period - but I guess this isn't possible now
> with varnish?
Actually it is. In the docs there is a somewhat dirty trick where set a
marker in vcl_error, restart and pick up on the error and switch backend to
one that is permanetly down. Grace kicks in and serves the stale content.
Sometime post 3.0 there will be a refactoring of the whole vcl_error
handling and we'll end up with something a bit more elegant.
Per Buer, Varnish Software
Phone: +47 21 98 92 61 / Mobile: +47 958 39 117 / Skype: per.buer
Varnish makes websites fly!
Want to learn more about Varnish?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the varnish-misc