On Fri, 11 Aug 2006, Philip M. Gollucci wrote:
>
> Mark Hedges wrote:
> > Maybe this is a regular apache users list question, sorry, but I figure
> > someone here might now.
> >
> > Server: Apache/2.0.55 (Debian) mod_apreq2-20051231/2.5.7 mod_perl/2.0.2
> > Perl/v5.8.8
> >
> > Using the regular cgi handler (no mod_perl fancy stuff), my warning messages
> > have this format:
> >
> > [Fri Aug 11 13:25:03 2006] [error] [client 127.0.0.1] ---, referer:
> > http://localhost/the_http_referer_page.html

> LogLevel debug
> ErrorLog logs/error_log
> LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\""
> combined
> LogFormat "%h %l %u %t \"%r\" %>s %b" common
> CustomLog logs/access_log common
> CustomLog logs/access_log combined


That would be awesome if it helped me, but it does not.

[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] , referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] this, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] is, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] a, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] test, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] of, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] the, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] emergency, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] broadcast, referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] system., referer: http://localhost/cgi-bin/mycart.cgi
[Fri Aug 11 17:44:31 2006] [error] [client 127.0.0.1] at /usr/lib/cgi-bin/mycart.cgi line 57., referer: http://localhost/cgi-bin/mycart.cgi


Like I said, it's the error log that is the problem, not the
access log.

I want to OMIT the date/loglevel/client before the warning lines
and to OMIT the referer after them. I want STDERR to be clean.

Here's an interesting behavior -- it always prints the prepended
info, but it only prints the appended referer on POST, not on GET.

Mark