<html><body><div style="color:#000; background-color:#fff; font-family:arial, helvetica, sans-serif;font-size:10pt"><div style="font-family: arial, helvetica, sans-serif; font-size: 10pt;"><br></div><div style="font-family: arial, helvetica, sans-serif; font-size: 13px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;">RRD is interpolating the value since you aren't inserting on the step-second (<span style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px;">1352425140&nbsp;</span><span style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px;">1352425200 etc...)</span></div><div style="background-color: transparent; color: rgb(0, 0, 0); font-size: 16px; font-family: 'times new roman', 'new york', times, serif; font-style: normal;"><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;"><br></div><div style="color: rgb(0, 0,
 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;">Since your insert is part way into the step interval of&nbsp;<span style="background-color: transparent; font-family: 'times new roman', 'new york', times, serif; font-size: 16px;">1352425140&nbsp;</span><span style="background-color: transparent;">rrd is splitting the value between the two step intervals.</span></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;">If you don't want interpolation the easiest way to avoid it is to subtract the modulus of time of 60 from time: time - (time % 60) ... gives you the step interval time to insert with.</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;"><br></div><div
 style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;">ps: you should also ensure that your loop code isn't doing a sleep 60, since you will drift in time with logic like that (that 3 seconds you gained between 121 and 184) ... use a wait counter that's based on: sync_time + 60 and wait until sync_time on each loop, etc.&nbsp;</div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-family: arial, helvetica, sans-serif; font-size: 13px; font-style: normal;"><br></div></div>  <div style="font-family: arial, helvetica, sans-serif; font-size: 10pt;"> <div style="font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;"> <div dir="ltr"> <font size="2" face="Arial"> <hr size="1">  <b><span style="font-weight:bold;">From:</span></b> Chris Nighswonger
 &lt;cnighswonger@foundations.edu&gt;<br> <b><span style="font-weight: bold;">To:</span></b> rrd-users@lists.oetiker.ch <br> <b><span style="font-weight: bold;">Sent:</span></b> Thursday, November 8, 2012 6:25 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> [rrd-users] Question about time stamp, etc with GAUGE DST<br> </font> </div> <br>
<div id="yiv480315317">What is it that I do not understand about the timestamps in the following RRD?&nbsp; Just below it is the actual data as inserted into the RRD via RRDs::update. Below that is the fetch of what the same data looks like in the RRD.<br>

<br>My question is why is the data from time 1352425184 split across two steps? I'm guessing it has to do with the difference between the --start value and when the logging daemon is started. What I am trying to achieve is the data point recorded in a single step. Is this possible?<br>

<br>Kind Regards,<br>Chris<br><br><br>RRD:<br><br>rrdtool create sperrors.rrd --start now --step 60 \<br>DS:align-err:GAUGE:120:0:100000 \<br>RRA:AVERAGE:0.5:1:10080 \<br>RRA:MAX:0.5:1:10080 \<br>RRA:LAST:0.5:1:1 \<br>RRA:AVERAGE:0.5:60:1440 \<br>

RRA:MAX:0.5:60:1440 \<br>RRA:AVERAGE:0.5:720:732 \<br>RRA:MAX:0.5:720:732<br><br><br>Data being inserted into RRD:<br><br>1352424941:0<br>1352425001:0<br>1352425061:0<br>1352425121:0<br>1352425184:2<br>1352425244:0<br>1352425304:0<br>

1352425364:0<br><br><br>Output of "$rrdtool fetch sperrors.rrd AVERAGE --start 1352424941"<br><br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; align-err<br><br>1352424960: 0.0000000000e+00<br>1352425020: 0.0000000000e+00<br>1352425080: 0.0000000000e+00<br>

1352425140: 6.3333333333e-01<br>1352425200: 1.4666666667e+00<br>1352425260: 0.0000000000e+00<br>1352425320: 0.0000000000e+00<br>1352425380: 0.0000000000e+00<br>1352425440: 0.0000000000e+00<br>1352425500: 0.0000000000e+00<br>

1352425560: 0.0000000000e+00<br><br>
</div><br>_______________________________________________<br>rrd-users mailing list<br><a ymailto="mailto:rrd-users@lists.oetiker.ch" href="mailto:rrd-users@lists.oetiker.ch">rrd-users@lists.oetiker.ch</a><br><a href="https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users" target="_blank">https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users</a><br><br><br> </div> </div>  </div></body></html>