This is a discussion on [rrd-users] can't sanity-check rrdtool with sample data ... please within the RRD Users forums, part of the Networking and Network Related category; --===============0922490123== Content-Type: multipart/alternative; boundary="0-1889256284-1182893659=:49895" Content-Transfer-Encoding: 8bit --0-1889256284-1182893659=:49895 ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
--===============0922490123==
Content-Type: multipart/alternative; boundary="0-1889256284-1182893659=:49895" Content-Transfer-Encoding: 8bit --0-1889256284-1182893659=:49895 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit New user of rrdtool. I plan on graphing the number of hits I get each day on my webserver. I have logs going back over a year, so my RRD will be backdated many months back and I will populate it with a script that parses my weblogs. Sounds very easy, but beause I am new I decided to just test it out and get a sense of how it worked. So I create an RRD: rrdtool create hits.rrd --start 1141200000 --step 86400 DS:hits:GAUGE:172800:0:U RRA:MAX:0.5:1:3650 starting about 13 months ago, step size is one whole day ... I thought that ABSOLUTE was a better choice for a discrete number every day, but every example I saw of web hits people were using GAUGE, so I guess I will too. Not sure if MAX is right, but the point is I do not want to do ANY averaging or summing or ANYTHING. I just want to plug in one number per day and graph that SINGLE number each day. The end. I assume MIN/MAX/LAST would provide the same results, right ? Ok, so the RRD creates without errors. Now I populate the first six days of data with make-believe values: rrdtool update hits.rrd 1141286400:1 1141372800:10 1141459200:10 1141545600:12 1141632000:12 1141718400:12 Easy. Start time is 1141200000, so my first value will be +86400, and adding +86400 each value after that. Again, this completes without errors. So, all is well - I'll just check the data with fetch to make sure it comes back just as I expect it to: # rrdtool fetch hits.rrd MAX --start 1141200000 --end 1141718400 hits 1141257600: 1.0000000000e+00 1141344000: 7.0000000000e+00 1141430400: 1.0000000000e+01 1141516800: 1.1333333333e+01 1141603200: 1.2000000000e+01 1141689600: 1.2000000000e+01 1141776000: nan And here are the problems. As you can see, the above output is completely wrong. The first, obvious, and mind-blowing behavior is that the time values in the output DO NOT MATCH my data points. My first data point was at time: 1141286400 and fetch returns that data point at: 1141257600 And then, the obvious problem that the data values are not correct - the values I entered into the RRD are clearly: 1,10,10,12,12,12 and fetch is giving me back: 1,7,1,11.3,12,12 (the 11.3 is particularly humurous) So, I give up. Is there a secret command line switch to "turn off the internal RNG that is applied to all dates and values" ? My question is simple: How do I plug in 6 test values with 6 specific dates and successfully fetch them back out again _exactly as I entered them_ ? Thanks. --------------------------------- Choose the right car based on your needs. Check out Yahoo! Autos new Car Finder tool. --0-1889256284-1182893659=:49895 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: 8bit New user of rrdtool.<br><br>I plan on graphing the number of hits I get each day on my webserver.<br><br>I have logs going back over a year, so my RRD will be backdated many months back and I will populate it with a script that parses my weblogs. Sounds very easy, but beause I am new I decided to just test it out and get a sense of how it worked.<br><br>So I create an RRD:<br><br>rrdtool create hits.rrd --start 1141200000 --step 86400 DS:hits:GAUGE:172800:0:U RRA:MAX:0.5:1:3650<br><br>starting about 13 months ago, step size is one whole day ... I thought that ABSOLUTE was a better choice for a discrete number every day, but every example I saw of web hits people were using GAUGE, so I guess I will too.<br><br>Not sure if MAX is right, but the point is I do not want to do ANY averaging or summing or ANYTHING. I just want to plug in one number per day and graph that SINGLE number each day. The end. I assume MIN/MAX/LAST would provide the same results, right ?<br><br>Ok, so the RRD creates without errors. Now I populate the first six days of data with make-believe values:<br><br>rrdtool update hits.rrd 1141286400:1 1141372800:10 1141459200:10 1141545600:12 1141632000:12 1141718400:12<br><br>Easy. Start time is 1141200000, so my first value will be +86400, and adding +86400 each value after that. Again, this completes without errors.<br><br>So, all is well - I'll just check the data with fetch to make sure it comes back just as I expect it to:<br><br># rrdtool fetch hits.rrd MAX --start 1141200000 --end 1141718400<br> &n bsp; &nbs p; hits<br><br>1141257600: 1.0000000000e+00<br>1141344000: 7.0000000000e+00<br>1141430400: 1.0000000000e+01<br>1141516800: 1.1333333333e+01<br>1141603200: 1.2000000000e+01<br>1141689600: 1.2000000000e+01<br>1141776000: nan<br><br><br>And here are the problems. As you can see, the above output is completely wrong.<br><br>The first, obvious, and mind-blowing behavior is that the time values in the output DO NOT MATCH my data points. My first data point was at time:<br><br>1141286400<br><br>and fetch returns that data point at:<br><br>1141257600<br><br>And then, the obvious problem that the data values are not correct - the values I entered into the RRD are clearly:<br><br>1,10,10,12,12,12<br><br>and fetch is giving me back:<br><br>1,7,1,11.3,12,12<br><br>(the 11.3 is particularly humurous)<br><br>So, I give up. Is there a secret command line switch to "turn off the internal RNG that is applied to all dates and values" ?<br><br>My question is simple: How do I plug in 6 test values with 6 specific dates and successfully fetch them back out again _exactly as I entered them_ ?<br><br>Thanks.<br><p> <hr size=1>Choose the right car based on your needs. Check out <a href="http://us.rd.yahoo.com/evt=48518/*http://autos.yahoo.com/carfinder/;_y...FyLWZpbmRlcg-- ">Yahoo! Autos new Car Finder tool.</a> --0-1889256284-1182893659=:49895-- --===============0922490123== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ rrd-users mailing list rrd-users@lists.oetiker.ch https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users --===============0922490123==-- |
![]() |
| Thread Tools | |
| Display Modes | |
|
|