I think what I've been playing with today is similar to what you want to do. I've got a sensor on my boiler that enables me to see when the burner is running. I want to see how long the burner runs in a given period. I've been using a 5 minute period so I don't have to wait long to see results. The graph is a plot of how many minutes the burner was on per 5 minute period. I don't know if this is the best way to do it, but it seems to be working:
<br><br>rrdtool create $sensor.rrd -s 300 \<br> DS:minutes:ABSOLUTE:300:0:5 \<br> RRA:MAX:0.5:1:2400 \<br> RRA:LAST:0.5:1:2400 \<br> RRA:MIN:0.5:1:2400 \<br> RRA:AVERAGE:
0.5:1:2400<br><br>I wasn't sure which RRA I'd want, but it turns out I'm only using the MAX one.<br>Every minute either a 0 or a 1 gets added, depending on whether the burner is on or off.<br><br>timenow=`date | sed 's/:/\\\:/g'`
<br>rrdtool graph $sensor.png \<br> --start -1_hour --alt-y-grid \<br> --height 190 --width 600 --imgformat PNG \<br> --vertical-label "minutes" \<br> DEF:ib1=$sensor.rrd:minutes:MAX \
<br> CDEF:mydata=ib1,300,* \<br> AREA:mydata#ff0000 \<br> COMMENT:"$timenow"<br><br>It took me a while to figure out that I was getting the rate per second, so I multiplied by 300 to get the rate per 5min (like Mr. Hobson said in his email).
<br>One thing I'm curious about is whether it's possible to make graphs of several rates from the same RRD file. For example, using the same RRD file to graph minutes per hour, per day, per week, etc. <br><br>-Ben
<br><br><br><div><span class="gmail_quote">On 1/23/07, <b class="gmail_sendername">Mike Sturdee</b> <<a href="mailto:sturdee@pathwaynet.com">sturdee@pathwaynet.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I am looking to graph some call data, with either the total number<br>of calls over 5 minutes put in rrd (or update the rrd each time a call<br>arrives, if possible) and then for each 5 minute increment, plot<br>the number of total calls in that time on the graph..
<br><br>While that part doesn't seem to difficult, in the historical<br>"weekly - 30min avg", "monthly - 2hour avg", etc, instead of being an<br>average over 30min, 2hour, etc, i would like to graph the sum total for
<br>calls per "30min, 2hour, etc" time period..<br><br>Is this at all possible with rrd?<br><br>Thanks,<br><br>-Mike<br><br>_______________________________________________<br>rrd-users mailing list<br><a 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">https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users</a><br></blockquote></div><br>