[rrd-users] Date/time-related problem on Windows

Tobias Oetiker tobi at oetiker.ch
Thu Nov 19 12:10:29 CET 2009


Hi Dod,

Today Dod wrote:

> Hello,
>
> I have a problem with win32 rrdtool (1.3.8 pre compiled version), I am
> rrdtool  beginner  and  used  it  only  once  for multiple temperature
> sensors draw so I am not experienced enought to fully understand fully
> how this powerfull RRDTool work.
>
> Today  I  want to use RDDTool again to graph HEC / CRC error's counter
> of DSL router, so I create a one minute step .rrd with enought rows to
> get more than a year of data.
>
> rrdtool create hec.rrd --start "1257698388" --step 60 DS:HEC:GAUGE:600:U:U RRA:AVERAGE:0:1:600000
>
> 1257698388 = 08 nov 2009 16:39:48
>
> But if I ask for rrdtool first and last I get weird values :
>
> first = 1221698400 = 18/09/2008 00:40:00 <= 2008 ???
> last =  1257698388 = 08/11/2009 16:39:48
>
> I don't understand first and last date, why 2008 , why last is --start
> value ?
>
> Now I add a few entries
>
> rrdtool update hec.rrd 1257698606 at 41907 1257698821 at 41907 1257698908 at 41907 1257698933 at 41907 1257698956 at 41907 1257698965 at 41907
>
> 1257698606 = 08/11/2009 16:43:26
> 1257698821 = 08/11/2009 16:47:01
> 1257698908 = 08/11/2009 16:48:28
> 1257698933 = 08/11/2009 16:48:53
> 1257698956 = 08/11/2009 16:49:16
> 1257698965 = 08/11/2009 16:49:25
>
> And ask first/last again
>
> first = 1221699000 = 18/09/2008 00:50:00 <= 10 minutes diff from previous request ???
> last =  1257698965 = 08/11/2009 16:49:25 OK this is real time of last entry
>
> Why first value differ from previous request ?

rrdtool stores data in a rotating buffer. the last (latest) value
in the buffer coresponds to the last time you update it. As you
create a new rrd you can define when it should expect the 'first'
input using the --start parameter (maybe oddly named). As you
create a new rrd file it stretches into the past fro the current
time or whatever you defined using --start

as you are filling the rrd with data it rolls forward, dropping off
the values stored at the end of the archive.  hence the name ...
round robin ....

hth
tobi


> regards.
>
> _______________________________________________
> rrd-users mailing list
> rrd-users at lists.oetiker.ch
> https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users
>
>

-- 
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-users mailing list