[squid-users] print errormessage (like %E in ERR_* pages) in squid logfile ?
Alex Rousskov
rousskov at measurement-factory.com
Wed Jun 17 14:24:21 UTC 2020
On 6/17/20 9:17 AM, Dieter Bloms wrote:
> more and more clients aren't browser but are programs, which call a
> restapi through our squid proxy.
>
> Those clients aren't able to show the errorpage (ERR_*) from proxy in
> case the request wasn't successful for any reason.
>
> I added %err_code and %err_detail, but %err_detail is filled with "-" sign all the
> time in the logfiles.
>
> For example:
> If the connection to a webserver fails %err_code is filled with ERR_CONNECT_FAIL, but
> %err_detail is filled with "-" instead of the messages "(110) Connection %timed out"
>
> Is it possible to log the error message like %E in the error pages ?
Hello Dieter,
No, it is not possible to log %E to access.log, and the errno-based
%E itself is often useless in such situations, especially in the
official code where it is often lost or stale.
However, your use case _is_ valid, and Factory is working on improving
detailing of various connectivity problems similar to the ones you are
talking about. There is no official pull request yet, but we are getting
very close. If you would like, please feel free to test-drive our
master/v6-based https://github.com/measurement-factory/squid/pull/63
HTH,
Alex.
More information about the squid-users
mailing list