Hello,<br><br>I&#39;m working with OpenNMS, a system which uses RRD for its graphing capabilities. I want to be able to generate reports on printer usage, since OpenNMS is already pulling in all that detailed SNMP data into RRDs, and it would be great if I could make these accessible via the OpenNMS interface. I&#39;ve got everything on the OpenNMS end set up, but I&#39;m having problems with the graph scripts, which is why I&#39;m here.<br>
<br>The printers track how many pages are printed over the printer&#39;s lifetime. Obviously, this isn&#39;t particularly useful when you&#39;re interested in frequency. What I need to do for each printer&#39;s Page Count RRA, then, should be straightforward.<br>
<br>1. Get lowest value.<br>2. Get highest value.<br>3. Subtract 1 from 2, and print.<br><br>However, I&#39;m not sure how to do this with RRD. I&#39;ve tried a bunch of different things, and here&#39;s what I&#39;ve got. It&#39;s a snippet from the OpenNMS config file, so it&#39;s not a pure command line script, but the only real difference is that {rrd1} is a program variable. So here goes.<br>
<br>/***<br>report.mib2printer.lifeCount.command=--title=&quot;Total Pages Printed&quot; \<br> --vertical-label=&quot;Pages Printed&quot; \<br> DEF:val1={rrd1}:lifeCount:AVERAGE \<br> DEF:minVal1={rrd1}:lifeCount:MIN \<br>
 DEF:maxVal1={rrd1}:lifeCount:MAX \<br> VDEF:start=minVal1:AVERAGE \<br> VDEF:endVal=maxVal1:AVERAGE \<br> LINE1:val1#00cc00:&quot;Total&quot; \<br> GPRINT:val1:AVERAGE:&quot; Avg \\: %8.2lf %s&quot; \<br> GPRINT:val1:MIN:&quot;Min \\: %8.2lf %s&quot; \<br>
 GPRINT:val1:MAX:&quot;Max \\: %8.2lf %s&quot; \<br> GPRINT:endVal-start:&quot; Pages Printed \\: %8.2lf %s&quot; \<br>***/<br><br>This runs just fine if I delete the last line. If I replace the two VDEFs with<br><br>CDEF:pageCount=maxVal1,minVal1,-<br>
<br>and add a line<br><br>GPRINT:pageCount:AVERAGE:&quot; Page Coutn \\: %8.2lf %s &quot;<br><br>Then the script runs, but the results are extremely inconsistent with the other numbers. It seems like it should be simple enough, and maybe I&#39;m just not looking at the right documentation, but I haven&#39;t had any luck with this so far. Could someone tell me if what I&#39;m trying to do is possible using RRD exclusively, and if so, how to do it?<br>
<br>Any assistance would be greatly appreciated.<br><br>Regards,<br>Travis<br><br>