[rrd-developers] thinking about localtime and graphing

Tobias Oetiker tobi at oetiker.ch
Fri Nov 25 15:21:32 CET 2011


in a customer project the 'localtime' question has come up
regarding graphs and consolidation.

rrdtool internally works in GMT, so a day in rrdtool is always GMT
aligned. If you define RRAs for 1 day intervals, this is what you
will get. With the world growing smaller, I still think this is a
good thing and I do not want to change it.

BUT for presentation it looks rather odd, when daily averages are
not aligned to the local 'idea' of a day.

So if you store hourly data in your RRAs, it would be nice if
rrdtool could build daily averages for 'local' days on the fly.

My idea is, to provide some additional parameters to the DEF function
in rrd graph to allow it to 'massage' the incoming data into
daily, weekly, monthly 'portions'. To make things as flexible as
possible, I think of employing the strftime function as a trigger
mechanism like that:

DEF:weekly=test.rrd:ifHCInOctets:AVERAGE:step=3600:ctrigger=%V:tz=CET

(%V would be the ISO week number,  but you could use any expression you want).

Whenever the value of the ctrigger changes, one 'grouping' comes to
an end. If the original data is not available at 'step' resolution
from rrd fetch, some interpolation might arificially enhance the
resolution prior the blocking it again.

I have not implemented anyting yet ... so please discuss

cheers
tobi

-- 
Tobi Oetiker, OETIKER+PARTNER AG, Aarweg 15 CH-4600 Olten, Switzerland
http://it.oetiker.ch tobi at oetiker.ch ++41 62 775 9902 / sb: -9900



More information about the rrd-developers mailing list