[rrd-users] Exporting numbers from rrdtool database
Alex van den Bogaerdt
alex at vandenbogaerdt.nl
Fri Mar 6 14:45:35 CET 2009
----- Original Message -----
From: "Stream Service" <info at streamservice.nl>
To: <rrd-users at lists.oetiker.ch>
Sent: Friday, March 06, 2009 2:09 PM
Subject: [rrd-users] Exporting numbers from rrdtool database
> Now I need the following information:
> - GB traffic for a certain problem (I had something for the MRTG logs, but
> it cannot read the rrdtool logs :( ), this period is normally the same as
> the period for the graph.
> - mbit(95%) traffic calculation for a certain period (this period is the
> same as the period for the GB traffic information).
>
> Both numbers should be in HTML/plaintekst/XML/etc. (so not in a picture).
RRDtool knows about PRINT, withouth a G, and then prints to stdout.
You have bytes per second in your RRD. If the average rate per second is,
say, 1GB/s, then on average 1GB was transfered every second. Thats 86400 GB
in a day, 7*86400 GB in a week, and so on. Just multiply the average rate by
the amount of time on the X-axis.
Printing the average rate using RRDtool is easy. Multiplying by the amount
of time you're interested in can be done inside or outside RRDtool.
Printing the 95th percentile is only slightly harder.
See the (online) docs, the tutorial, or this:
http://www.vandenbogaerdt.nl/rrdtool/total.php
More information about the rrd-users
mailing list