Varnish returns truncated content

MAGNIEN, Thierry thierry.magnien at
Wed Apr 6 21:41:09 CEST 2016


For this kind of setup, you can cut your storage in half and use two stevedores: one for small files and other for large ones. Use vcl to decide in which stevedore you store objects.

You'll avoid nuking too many small objects for a single large one.


-------- Message d'origine --------
De : John Salmon <John.Salmon at>
Date : 06/04/2016 20:09 (GMT+01:00)
À : Dridi Boukelmoune <dridi at>
Cc : varnish-misc <varnish-misc at>, "Moraes, Mark" <Mark.Moraes at>
Objet : Re: Varnish returns truncated content

On 04/06/2016 11:54 AM, Dridi Boukelmoune wrote:

Is this a Varnish bug?  Any advice on how to diagnose this further would be

Hi John,

This is not a bug, but probably due to streaming being enabled by
default. Basically the request goes through the VCL successfully, the
curl client gets the headers and then the body is streamed while at
the same time inserted into storage.

But then you get this error:

-   FetchError     Could not get storage

You can see lots of ExpKill records, which mean that you most likely
hit the nuke_limit (see man varnishd). It means that Varnish stopped
making space for the new object because for that it had to remove too
many objects from the cache. It may happen more frequently when a
storage is mixing large and small objects.

Yes.  I definitely have a mix of small O(100) byte objects
and large (up to 8MB) objects.  How should I set nuke_limit?
80000 would more-or-less guarantee that space can be found
for a large object by nuking small ones.  Are there negative
consequences to setting it so high?  Are there other parameters
I should tune instead/first?

John Salmon

Best Regards,

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

More information about the varnish-misc mailing list