[rrd-users] Question about averaging daily ; but with 5 min. steps

Alex van den Bogaerdt alex at vandenbogaerdt.nl
Mon Dec 14 23:18:59 CET 2009


> If I want to measure it in kWh, I think that's what I'm going to do :)

Funny. So you don't disagree with the "or, if you want, kWh" below but you 
still feel necessary to attack me?

>> Make sure you understand W=J/s and kWh = 1000*3600*1J. Inside rrdtool
>> everything is <something> per second, so inside rrdtool you should store
>> Joules (or, if you want, kWh) which will show up as Joules per second aka
>> Watt.

> sigh...

> Did it seem to you that I had any issues converting units ?

It still does. Else you would understand that this 'problem' is no different 
from having bits (or megabytes) in your database and using CDEF and GPRINT 
to display the average, after being multiplied by 86400, to get the amount 
of bits (or megabytes) in a day.

Or, if you like the automobile examples better, you measure meters, or 
kilometers, or miles. This will become meters (or kilometers, or miles) per 
second. Then you let RRDtool compute the average after multiplying by 86400 
to get meters (or kilometers, or miles) in a day.

Yes, it's that simple.  You start with a number of Joules (or kWh) per 
second, you multiply by a number of seconds, and end up with a number of 
Joules (or kWh).

If the average is 1J/s (== 1W), and if you multiply by 86400s, you can cross 
out the 's' units and end up with 86400J. And if you input kWh instead of J, 
you end up with kWh instead of J. Which is what you ask for.



More information about the rrd-users mailing list