More Descriptive 502 Errors

Every so often I see a handful of errors in my error log, such as:

connect() failed (113: No route to host)
upstream timed out (110: Connection timed out)
upstream sent too big header while reading response header from upstream

etc.

in each case, when I log the $status variable in nginx, each just shows
as a
502 error. Is there any way to retrieve what the actual error is (via
variable?) without having to check the error log or is that the only
source
for this information?

Thanks!

Posted at Nginx Forum:

Hello!

On Wed, Apr 02, 2014 at 03:44:45PM -0400, abstein2 wrote:

variable?) without having to check the error log or is that the only source
for this information?

The error log is the only place where error details are logged.


Maxim D.
http://nginx.org/