[mrtg] Displaying period-aggregate traffic

Geoff Powell geoff at g8kbz.demon.co.uk
Thu Aug 16 18:23:18 CEST 2007

Since my ISP has recently imposed a "Fair Use Policy" limit of 60GB, on
a rolling 30 day average, on my "up to 8Mbit/sec" ADSL connection (which
has a data sync rate of 7616kbit/sec) I would like to display, in real-
time, aggregate traffic for that same period.

I have MRTG running with rateup not RRDTool, and monitoring my ADSL
router, and that is all working fine.

I have heard of, and tried, Tobi's traffic-summer Perl script, which
seems to run, but doesn't present any significant data - all I see is
the report header. There's probably something weird in the "catch" regex
that is preventing the thing working, and I'm insufficiently familiar
with both Perl and regexes to debug it. All my attempts to insert
sprintf statements to try to see what the script is doing lead to
nothing significant, except complaints from Perl.

But it also reports for the last calendar month, not a rolling 30 day
total, and it won't run as an MRTG helper script.

So my question is (or maybe are) - can I do this? Does anyone have a
script that will work as above, or a set of patches to traffic-summer
that will do the trick?

And before anyone posts about that download cap - yes, I know I'm lucky,
there are people here in UK who have the same "up to 8Mbit" deal, and a
usage cap of 2GB per month. I commiserate with them.

Geoff Powell

More information about the mrtg mailing list