Explaining internal errors

From: Alex Rousskov <rousskov_at_measurement-factory.com>
Date: Mon, 28 Jun 2010 13:12:27 -0600

Hello,

    Squid may respond with HTTP 500 Internal Server Error
(HTTP_INTERNAL_SERVER_ERROR) when we hit a bug or when the communication
with another server fails. The admin may need to distinguish these and
other cases (and their sub-cases) because they may require different
administration actions (e.g., fix a broken ICAP server or configure more
ephemeral ports).

Some of the corresponding errors are also reported in cache.log but many
are not. Moreover, it is often difficult to correlate cache.log and
access.log information, especially on a busy proxy. When we are asked to
triage or explain various TCP_MISS/500 and NONE/500 log entries, we have
very few usable sources of information.

I suggest adding two new access.log format codes that will contain the
error page ID returned by Squid and the corresponding "error details".

The "error page ID" field will explain, in most cases, what happened. We
will log such strings as ERR_SHUTTING_DOWN and ERR_UNSUP_REQ. These will
come from the err_type enum and the error page ID already maintained by
Squid.

The "error detail" field will detail why the error happened, helping to
distinguish different causes for the same error page ID. The exact
interpretation of the details will depend on the error page ID. For
example, it could be the OS error number for I/O-related errors.

Any objections or better ideas?

Thank you,

Alex.
P.S. Squid may also forward HTTP 500 status code from the origin server,
but those cases are already detectable via %http::<Hs.
Received on Mon Jun 28 2010 - 19:13:16 MDT

This archive was generated by hypermail 2.2.0 : Tue Jun 29 2010 - 12:00:07 MDT