This is a discussion on [rrd-users] Fetch with --resolution parameter within the RRD Users forums, part of the Networking and Network Related category; Hi, I've created an RRD database to store a value (server clock offset in ms). I've created a ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi,
I've created an RRD database to store a value (server clock offset in ms). I've created a cron job to add the value every 6 hours. I created the file with: rrdtool create file.rrd -s 21600 DS:offset:GAUGE:21600:U:U RRA:MAX:0:1:360 I add the data with: rrdtool update file.rrd timestamp:<val> And I query data with: rrdtool fetch file.rrd MAX -r 86400 -s 1210766400 -e 1211371200 So I read a value four times a day (every 21600s) and my resolution (-r) parameter is 4 * 21600 so I'm expecting one value for each day, i.e. seven values. The difference between start and end values is also a multiple of 86400. However, I get 29 values. Can anyone tell me what I'm doing wrong? Thanks in advance, Leon ----------------------------------------- Email sent from www.virginmedia.com/email Virus-checked using McAfee(R) Software and scanned for spam _______________________________________________ rrd-users mailing list rrd-users@lists.oetiker.ch https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users |
|
|||
|
Leon Stringer wrote:
>And I query data with: > > rrdtool fetch file.rrd MAX -r 86400 -s 1210766400 -e 1211371200 > >So I read a value four times a day (every 21600s) and my resolution >(-r) parameter is 4 * 21600 so I'm expecting one value for each day, >i.e. seven values. The difference between start and end values is >also a multiple of 86400. However, I get 29 values. > >Can anyone tell me what I'm doing wrong? your start and end times are 7 days apart, 7x4 is 28, include both the start and end times and that makes 29. What you are doing wrong is not understanding what the tool is doing. The resolution option merely tells fetch which existing RRA to use (in this case you are trying to select a non-existent RRA), it does NOT resample the data to some arbitrary step size. _______________________________________________ rrd-users mailing list rrd-users@lists.oetiker.ch https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users |