Cacti (home)ForumsDocumentation
Cacti: offical forums and support
It is currently Thu May 23, 2019 4:01 am

All times are UTC - 5 hours




Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Data source not graphed correctly
PostPosted: Thu Apr 17, 2008 4:31 pm 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
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


Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 18, 2008 10:01 am 
Offline
Developer
User avatar

Joined: Thu Dec 02, 2004 2:46 am
Posts: 22376
Location: Muenster, Germany
Please post those findings from following the NaN debugging, step-by-step.
Reinhard

_________________
Official Cacti Documentation
Official Debugging Help
Central Plugin Repository
Central Templates Repository


Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 18, 2008 4:21 pm 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
I'm not currently getting NAN's on the graphs, I removed that graph and data source then recreated them. Now its just graphing the current average. I would like it to graph the total.


Top
 Profile  
 
 Post subject: Re: Data source not graphed correctly
PostPosted: Sat Apr 19, 2008 7:10 am 
Offline
Developer
User avatar

Joined: Thu Dec 02, 2004 2:46 am
Posts: 22376
Location: Muenster, Germany
jrohr wrote:
Hello,
I'm trying to get a SNMP Generic OID template to return the total value
Please post a screenshot of the Graph Template used
Reinhard

_________________
Official Cacti Documentation
Official Debugging Help
Central Plugin Repository
Central Templates Repository


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 21, 2008 8:24 am 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
Here are the screenshots


Attachments:
File comment: Graph Template screenshot 1
cacti1.jpg
cacti1.jpg [ 372.46 KiB | Viewed 3818 times ]
File comment: Graph Template screenshot 2
cacti2.jpg
cacti2.jpg [ 278.16 KiB | Viewed 3818 times ]
Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 21, 2008 2:35 pm 
Offline
Developer
User avatar

Joined: Thu Dec 02, 2004 2:46 am
Posts: 22376
Location: Muenster, Germany
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

_________________
Official Cacti Documentation
Official Debugging Help
Central Plugin Repository
Central Templates Repository


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 22, 2008 8:49 am 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
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?


Attachments:
File comment: Data Template screen1
cacti dt1.jpg
cacti dt1.jpg [ 341.46 KiB | Viewed 3776 times ]
File comment: Data Template screen2
cacti dt2.jpg
cacti dt2.jpg [ 318.21 KiB | Viewed 3776 times ]
File comment: Data Source
cacti ds.jpg
cacti ds.jpg [ 316.29 KiB | Viewed 3776 times ]
Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 22, 2008 1:55 pm 
Offline
Developer
User avatar

Joined: Thu Dec 02, 2004 2:46 am
Posts: 22376
Location: Muenster, Germany
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

_________________
Official Cacti Documentation
Official Debugging Help
Central Plugin Repository
Central Templates Repository


Top
 Profile  
 
 Post subject:
PostPosted: Thu Apr 24, 2008 2:19 pm 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
OK, I changed the first Graph Template item from AVERAGE to LAST and made sure the RRA's used include LAST cf. The graph was recreated after making these changes but it still only shows the AVERAGE.


Attachments:
File comment: Graph
graph.jpg
graph.jpg [ 70.05 KiB | Viewed 3709 times ]
Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 25, 2008 2:27 pm 
Offline
Developer
User avatar

Joined: Thu Dec 02, 2004 2:46 am
Posts: 22376
Location: Muenster, Germany
Please select this graph from graph management, switch to debug and post resultrs
Reinhard

_________________
Official Cacti Documentation
Official Debugging Help
Central Plugin Repository
Central Templates Repository


Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 25, 2008 4:02 pm 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
Code:
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


I'm not sure why this isn't working... eveything looks right. Let me know if there's something I should double or triple check.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Apr 26, 2008 3:28 am 
Offline
Developer
User avatar

Joined: Thu Dec 02, 2004 2:46 am
Posts: 22376
Location: Muenster, Germany
Fine, now I need result of
Code:
rrdtool info hp2800_marketing_hp_pg_count3_212.rrd
Post the first 30 lines only
Reinhard

_________________
Official Cacti Documentation
Official Debugging Help
Central Plugin Repository
Central Templates Repository


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 28, 2008 10:13 am 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
Code:
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
...


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 28, 2008 12:06 pm 
Offline
Developer
User avatar

Joined: Thu Dec 02, 2004 2:46 am
Posts: 22376
Location: Muenster, Germany
jrohr wrote:
Yes, I want the total pages printed.
So you want to print the absolute value of the number of pages printed by this printer during his life?

Quote:
I am already using a COUNTER but it doesn't graph as a counter.
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!

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

_________________
Official Cacti Documentation
Official Debugging Help
Central Plugin Repository
Central Templates Repository


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 29, 2008 10:15 am 
Offline

Joined: Wed Sep 12, 2007 2:38 pm
Posts: 23
Quote:
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!

Your latest post clears up some things.

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:
File comment: working graph
graph2.jpg
graph2.jpg [ 62.86 KiB | Viewed 3530 times ]
Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next

All times are UTC - 5 hours


Who is online

Users browsing this forum: Bing [Bot] and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

Protected by Anti-Spam ACP Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group