Intermittent 503 errors in varnish cache server due to backend fetch failure
I am getting 503 backend fetch failed errors intermittently after many successful requests. They keep on occuring at random times.
this is the varnish log sample for error:
- << Request >> 28612478
- Begin req 28612475 rxreq
- Timestamp Start: 1469259438.392350 0.000000 0.000000
- Timestamp Req: 1469259438.392350 0.000000 0.000000
- ReqStart 10.201.1.11 49351
- ReqMethod GET
- ReqURL some url
- ReqProtocol HTTP/1.1
- ReqHeader Content-Type: application/json
- ReqHeader Host: SomeHost
- ReqHeader Connection: Keep-Alive
- ReqHeader User-Agent: Apache-HttpClient/4.1 (java 1.5)
- ReqHeader X-Forwarded-For: 10.201.1.11
- VCL_call RECV
- ReqURL some url
- ReqURL some url
- VCL_return hash
- VCL_call HASH
- VCL_return lookup
- VCL_call MISS
- VCL_return fetch
- Link bereq 28612479 fetch
- Timestamp Fetch: 1469259441.892771 3.500421 3.500421
- RespProtocol HTTP/1.1
- RespStatus 503
- RespReason Backend fetch failed
- RespHeader Date: Sat, 23 Jul 2016 07:37:21 GMT
- RespHeader Server: Varnish
- RespHeader Content-Type: text/html; charset=utf-8
- RespHeader Retry-After: 5
- RespHeader X-Varnish: 28612478
- RespHeader Age: 0
- RespHeader Via: 1.1 varnish-v4
- VCL_call DELIVER
- VCL_return deliver
- Timestamp Process: 1469259441.892804 3.500454 0.000034
- RespHeader Content-Length: 285
- Debug "RES_MODE 2"
- RespHeader Connection: keep-alive
- Timestamp Resp: 1469259441.892848 3.500498 0.000043
- ReqAcct 776 0 776 242 285 527
- End
I have tried tuning so many parameters, but not able to get rid of these errors.
Thanks in advance.