Re: Bandwidth Monitoring per Directory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hmm.. I figured that Apache would only log the actual transfer amount ,not
just the file size.

If you look at most "web traffic" software ,they pretty much just analyze
log files . The difference is in just how fancy they can make the output
look :) I looked in my O'Reilly Apache Cookbook last night and they didn't
have anything like this either.  As you said in your email, it looks like
this is not an Apache thing.


Here's what I expect you'll have to do.

Log all the regular HTML traffic (i.e. downloads under 30K) with the apache
logs.  The error in calculation here isn't too big.  So you can utilize the
apache logging there.

Track all the big downloads by writing your own download software (PHP,
Perl, etc.) . So when they click on a file to download, it goes through your
php/perl wrapper first which you'll have to program to track the amount of
data sent .  Don't ask me how :)  It'd take me awhile to figure out also.
The only ways I can think of to do it would result in huge performance hits
on file downloads (like downloading the file to the browser in 5K chunks and
tallying those up, very yucky way to do it and undesirable).

The less performance hit way to do it would be to get a network traffic
monitoring tool which can accurately tally your traffic.  Problem there is
that these aren't usually application aware so I don't know how you'd relate
the traffic stats back to your separate users.  I would say this direction
is probably your better bet.

Sorry couldn't help you much.
Good luck.   I'ts an interesting question and I'll keep thinking about it.

Ben Y

== Original Message Follows ==
Hmmm, it would seem that the log file merely puts in the filesize.  Not
the amount it transferred.  I test it with a 10Mb file, and cut it off
after 500k ish, and it still reported 10Mb.  I don't think apache can
do this by itself.  I need a mixture of cgi scripts/bash scripts/perl
etc

Still lost...and in need of a hard kick in the right direction.

Thanks


-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux