ehall wrote:While you are in the device screen, hit the Verbose Query option next to the data source, and post the results please.
If the CPUs show up with index value of 1 and 3, then you'll need to recreate the graphs. You'll probably want to delete the old ones too.
Here's what I got, what's the verdict? Looks like recreating will be required...:
+ Running data query [14].
+ Found type = '4 '[script query].
+ Found data query XML file at '/usr/share/cacti/resource/script_queries/cisco_cpu.xml'
+ XML file parsed ok.
+ Executing script for list of indexes '/usr/bin/php5 -q /usr/share/cacti/scripts/cisco_cpu_usage.php r1.com, 02r, 1, , , 161, 500 index'
+ Executing script query '/usr/bin/php5 -q /usr/share/cacti/scripts/cisco_cpu_usage.php 2r1.com, 02r, 1, , , 161, 500 query cpuIndex'
+ Found item [cpuIndex='1.3.6.1.4.1.9.9.109.1.1.1.1.2.1'] index: 1.3.6.1.4.1.9.9.109.1.1.1.1.2.1
+ Found item [cpuIndex='1.3.6.1.4.1.9.9.109.1.1.1.1.2.3'] index: 1.3.6.1.4.1.9.9.109.1.1.1.1.2.3
+ Executing script query '/usr/bin/php5 -q /usr/share/cacti/scripts/cisco_cpu_usage.php 2r1com, 02r, 1, , , 161, 500 query cpuName'
+ Found item [cpuName='CPU1.3.6.1.4.1.9.9.109.1.1.1.1.2.1'] index: 1.3.6.1.4.1.9.9.109.1.1.1.1.2.1
+ Found item [cpuName='CPU1.3.6.1.4.1.9.9.109.1.1.1.1.2.3'] index: 1.3.6.1.4.1.9.9.109.1.1.1.1.2.3
+ Executing script query '/usr/bin/php5 -q /usr/share/cacti/scripts/cisco_cpu_usage.php 2r1.com, 02r, 1, , , 161, 500 query cpuDesc'
+ Found item [cpuDesc='onboard CPU'] index: 1.3.6.1.4.1.9.9.109.1.1.1.1.2.1
+ Found item [cpuDesc='onboard CPU'] index: 1.3.6.1.4.1.9.9.109.1.1.1.1.2.3
+ Found data query XML file at '/usr/share/cacti/resource/script_queries/cisco_cpu.xml'
+ Found data query XML file at '/usr/share/cacti/resource/script_queries/cisco_cpu.xml'
+ Found data query XML file at '/usr/share/cacti/resource/script_queries/cisco_cpu.xml'
+ Found data query XML file at '/usr/share/cacti/resource/script_queries/cisco_cpu.xml'
+ Found data query XML file at '/usr/share/cacti/resource/script_queries/cisco_cpu.xml'
{Update}
Still nothing showing up in the graphs. I removed the query from the device and then deleted the graphs and the data sources. I then recreated all of them and waited for the next poll - nada. This is what I get, beyond the above, running debug on the graph. I'm wondering if it should read "CPU1.3..." or "CPU 1.3..."?
RRDTool Command:
/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="2r1 - CPU Usage - CPU1.3.6.1.4.1.9.9.109.1.1.1.1.2.1 (onboard CPU)" \
--rigid \
--base=1000 \
--height=120 \
--width=600 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="Percent" \
--slope-mode \
DEF:a="/usr/share/cacti/rra/2r1_fivemin_1558.rrd":oneMin:AVERAGE \
DEF:b="/usr/share/cacti/rra/2r1_fivemin_1558.rrd":fiveMin:AVERAGE \
CDEF:cdefi=TIME,1137077458,GT,a,a,UN,0,a,IF,IF,TIME,1137077458,GT,b,b,UN,0,b,IF,IF,+ \
AREA:a#FFC73B:"1 Min Avg" \
GPRINT

LAST:"Current\:%8.2lf" \
GPRINT

AVERAGE:"Average\:%8.2lf" \
GPRINT

MAX:"Maximum\:%8.2lf\n" \
AREA:b#EA8F00:"5 Min Avg":STACK \
GPRINT

LAST:"Current\:%8.2lf" \
GPRINT

AVERAGE:"Average\:%8.2lf" \
GPRINT

MAX:"Maximum\:%8.2lf\n" \
LINE1:cdefi#000000:""
RRDTool Says:
OK