Varnish Closing Backend Connection

Junaid Mukhtar junaid.mukhtar at
Wed Nov 28 16:11:50 UTC 2018

hi Guys

I am facing a rather tricky issue, where it appears that the varnish is
closing the backend connection without waiting for a respones from the

We are using Nginx to serve static content Below is teh sequence of messages

Varnish sends POST request to App
App sends back 500 Internal Server Error
Varnish interprets the 500 internal Server Error
Varnish sends GET request to Nginx server on the same box to serve static
Varnish shows error message (even though Nginx sends the response
successfully within milliseconds)
-   VCL_call       BACKEND_FETCH
-   VCL_return     fetch
-   BackendOpen    38 boot.staticpages 82 35064
-   BackendStart 82
-   FetchError     backend write error: 0 (Success)
-   Timestamp      Bereq: 1543420795.016075 5.106813 0.000099
-   BackendClose   38 boot.staticpages
-   Timestamp      Beresp: 1543420795.016497 5.107235 0.000422
-   Timestamp      Error: 1543420795.016503 5.107241 0.000005
-   BerespProtocol HTTP/1.1
-   BerespStatus   503
-   BerespReason   Service Unavailable
-   BerespReason   Backend fetch failed
-   BerespHeader   Date: Wed, 28 Nov 2018 15:59:55 GMT
-   BerespHeader   Server: Varnish
-   VCL_call       BACKEND_ERROR

Varnish then again goes the same Nginx server to display default content.
Nginx sends response and varnish accepts it and sends it back to the

I am a bit stumped, any help with this is highly appreciated

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

More information about the varnish-misc mailing list