BackGroundFetch problem ?

zart zurt zartzurter at
Thu Oct 25 08:56:54 UTC 2018

Hi, I recently adopted some varnish servers and upgraded them to varnish
5.0.0 in debian-9 from the debian repositories.

Most metrics are good except the backend_req value which is too high. The
default_ttl and TTL values set in the VCL code are all 10d (or equivalent
in seconds)

When I checked the docs, I found out that in vcl_hit even if you return
deliver, varnish starts a background fetch for that particular object if
the object time has passed its TTL. In my case, BGF is always started.

I checked the source code and in file varnisgd/cache/cache_req_fsm.c and
function cnt_lookup around line 540, after VCL_hit_method called and it
returned VCL_RET_DELIVER, a BGF is started without looking at the TTL value.

How can I change this behaviour in VCL or through a parameter ? Or is this
a bug ?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the varnish-dev mailing list