Data source not graphed correctly
Moderators: Developers, Moderators
Data source not graphed correctly
Hello,
I'm trying to get a SNMP Generic OID template to return the total value but it keeps giving me an average. I setup a Data template w/ a Data Source item that uses COUNTER and has a max value of 500000000. Also, setup a Graph template w/ 3 graph items: Total (Line2, Average), Min (Gprint, Min) and Current (Gprint, Last).
The first time I set this up it worked fine for a day or so then I got NAN's on that graph. I went through the Debug NAN's tutorial and could not find any problems. At that point I removed that graph and data source and recreated them. I'm also getting the correct result if I run an snmpget from the command line.
How can I troubleshoot this further?
Thanks
jrohr
I'm trying to get a SNMP Generic OID template to return the total value but it keeps giving me an average. I setup a Data template w/ a Data Source item that uses COUNTER and has a max value of 500000000. Also, setup a Graph template w/ 3 graph items: Total (Line2, Average), Min (Gprint, Min) and Current (Gprint, Last).
The first time I set this up it worked fine for a day or so then I got NAN's on that graph. I went through the Debug NAN's tutorial and could not find any problems. At that point I removed that graph and data source and recreated them. I'm also getting the correct result if I run an snmpget from the command line.
How can I troubleshoot this further?
Thanks
jrohr
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
Re: Data source not graphed correctly
Please post a screenshot of the Graph Template usedjrohr wrote:Hello,
I'm trying to get a SNMP Generic OID template to return the total value
Reinhard
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
So you want to graph the "pages printed" counter of that printer, correct? Not the "numbers of pages printed per minute"?
How did you read out the value? Using SNMP? Which OID? Please post result of an snmpwalk against the OID used.
How did you define the data source. For your goal, you need COUNTER!
Reinhard
How did you read out the value? Using SNMP? Which OID? Please post result of an snmpwalk against the OID used.
How did you define the data source. For your goal, you need COUNTER!
Reinhard
Yes, I want the total pages printed.
I'm using a generic SNMP template where I specify the OID. It is .1.3.6.1.2.1.43.10.2.1.4.1.1
C:\Net-SNMP>snmpwalk -c public -v1 65.89.140.84 .1.3.6.1.2.1.43.10.2.1.4.1.1
SNMPv2-SMI::mib-2.43.10.2.1.4.1.1 = Counter32: 269
I am already using a COUNTER but it doesn't graph as a counter. I'm including screenshots of the Data Template and Data Source. Can you check them to see if anything looks out of place?
I'm using a generic SNMP template where I specify the OID. It is .1.3.6.1.2.1.43.10.2.1.4.1.1
C:\Net-SNMP>snmpwalk -c public -v1 65.89.140.84 .1.3.6.1.2.1.43.10.2.1.4.1.1
SNMPv2-SMI::mib-2.43.10.2.1.4.1.1 = Counter32: 269
I am already using a COUNTER but it doesn't graph as a counter. I'm including screenshots of the Data Template and Data Source. Can you check them to see if anything looks out of place?
- Attachments
-
- Data Source
- cacti ds.jpg (316.29 KiB) Viewed 4527 times
-
- Data Template screen2
- cacti dt2.jpg (318.21 KiB) Viewed 4527 times
-
- Data Template screen1
- cacti dt1.jpg (341.46 KiB) Viewed 4527 times
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
That's all fine. You should see the AVERAGE consolidation of that COUNTER; it should increase steadily. If you'd like to see LAST consolidation (which makes sense in this case), edit the first Graph Template Item and change AVERAGE to LAST. Make sure, that the RRAs used include LAST cf.
Post a screenshot of the Graph, please
Reinhard
Post a screenshot of the Graph, please
Reinhard
Code: Select all
RRDTool Command:
c:/rrdtool/rrdtool.exe graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="HP2800_Marketing Total Printed Pages (generic)" \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="" \
--slope-mode \
--font TITLE:12: \
--font AXIS:8: \
--font LEGEND:10: \
--font UNIT:8: \
DEF:a="c\:/Inetpub/wwwroot/cacti/rra/hp2800_marketing_hp_pg_count3_212.rrd":hp_pg_count3:LAST \
DEF:b="c\:/Inetpub/wwwroot/cacti/rra/hp2800_marketing_hp_pg_count3_212.rrd":hp_pg_count3:AVERAGE \
LINE2:a#FF0000:"Total Pages" \
GPRINT:b:MIN:"Min\:%8.0lf" \
GPRINT:a:LAST:"Current\:%8.0lf"
RRDTool Says:
OK
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
Fine, now I need result of Post the first 30 lines only
Reinhard
Code: Select all
rrdtool info hp2800_marketing_hp_pg_count3_212.rrd
Reinhard
Code: Select all
C:\RRDTool>rrdtool info c:\Inetpub\wwwroot\cacti\rra\hp2800_marketing_hp_pg_count3_212.rrd
filename "c:\Inetpub\wwwroot\cacti\rra\hp2800_marketing_hp_pg_count3_212.rrd"
rrd_version = "0003"
step = 300
last_update = 1209395294
ds[hp_pg_count3].type = "COUNTER"
ds[hp_pg_count3].minimal_heartbeat = 600
ds[hp_pg_count3].min = 0.0000000000e+00
ds[hp_pg_count3].max = 5.0000000000e+08
ds[hp_pg_count3].last_ds = "426"
ds[hp_pg_count3].value = 0.0000000000e+00
ds[hp_pg_count3].unknown_sec = 0
rra[0].cf = "AVERAGE"
rra[0].rows = 500
rra[0].pdp_per_row = 1
rra[0].xff = 5.0000000000e-01
rra[0].cdp_prep[0].value = NaN
rra[0].cdp_prep[0].unknown_datapoints = 0
rra[1].cf = "AVERAGE"
rra[1].rows = 600
rra[1].pdp_per_row = 1
rra[1].xff = 5.0000000000e-01
rra[1].cdp_prep[0].value = NaN
rra[1].cdp_prep[0].unknown_datapoints = 0
rra[2].cf = "AVERAGE"
rra[2].rows = 700
rra[2].pdp_per_row = 6
rra[2].xff = 5.0000000000e-01
rra[2].cdp_prep[0].value = 0.0000000000e+00
rra[2].cdp_prep[0].unknown_datapoints = 0
rra[3].cf = "AVERAGE"
rra[3].rows = 775
rra[3].pdp_per_row = 24
...
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
So you want to print the absolute value of the number of pages printed by this printer during his life?jrohr wrote:Yes, I want the total pages printed.
I cannot confirm. You've set up each and everything as required by a COUNTER. But your assumption may go wrong when you assume, that a COUNTER will graph the grand total! It won't! A standard COUNTER will always print the "rate" only!I am already using a COUNTER but it doesn't graph as a counter.
To sum up:
You may change the ds_type of the rrd file from COUNTER to GAUGE. In this case, rrdtool will NOT automatically compute the difference to the last update. You may achieve this by using rrdtool tune for the existing rrd file (Note: changing the data template is fine but this will NOT change existing rrd files).
But please pay attention to the devices behaviour. It's very likely that the print counter will be reset on printer reboot.
Hope we've got it now
Reinhard
Your latest post clears up some things.So you want to graph the "pages printed" counter of that printer, correct? Not the "numbers of pages printed per minute"? ... For your goal, you need COUNTER!
I duplicated the Graph Template, Graph Mgmt, created a new graph and Data Source, then changed the DS type from COUNTER to GAUGE. After doing this it is graphing correctly.
Also, the page count (impressions) is a total of pages printed through a JetDirect card. This number is not reset when powering off the printer or the JetDirect device. This is essentially what servicemen use to check the miles of a printer.
Thanks for your help!
- Attachments
-
- working graph
- graph2.jpg (62.86 KiB) Viewed 4281 times
Who is online
Users browsing this forum: No registered users and 1 guest