httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bojan Smojver <>
Subject Re: [PROPOSAL]: Bytes received v. mod_log_config
Date Mon, 19 Aug 2002 03:57:14 GMT
Quoting Chris Taylor <>:

> Yes, definately.
> FWIW, I find it quite annoying that Webalizer's "amount served" is
> often blindingly inaccurate based on Apache's logs.

I think this is due to the fact that headers are not taken into account or
something like that. And there is also the mod_gzip factor that might change
things significantly. mod_accounting (
has some workarounds to produce a bit more accurate numbers. I also had a brief
look at webalizer code and I'll be producing a patch that takes advantage of the
number of input bytes stored in the log file, most likely as the last field, to
remain compatible with current standards.

> I hadn't realised this way possible, but it sounds like a great idea
> to me :)

I had a brief chat to the author of mod_accounting, Simone Tellini, about
pinching his routine(s) that calculates the number of input bytes. It is rather
simple, it just adds the strlen of request, lengths of all headers and specified
content-length, plus relevant CRLF pairs. mod_accounting takes database
approach, however, to record the input/output bytes, but I felt it would be
appropriate to extend the log files with such information as well.

As with anything open source, my motivation is purely selfish - I get charged
for input traffic, so I want my clients to pay accordingly. However, I don't
want to employ proprietary, restricted of closed source solutions for any of
that. So, I started scratching...

Once I'm happy with the code I'll send it to the list.


View raw message