CBWFQ stats collector for Cisco
Moderators: Developers, Moderators
I am seeing an incorrect value returned by the qospol.pl script:
#./qospol.pl <host_IP> <comm> 2 get QoSdropperclass 27729.27731
this
#
I know the last two numbers are correct for the interface and the class type (an snmpwalk of 1.3.6.1.4.1.9.9.166.1.15.1.1.14.27729 produces correct values).
It seems the perl script is not parsing the output correctly and returning the string "this" instead of a numerical value?
I have tried changing the "print $ifpol1[13]" to 18 or other values with no luck.
Help? Thx.
#./qospol.pl <host_IP> <comm> 2 get QoSdropperclass 27729.27731
this
#
I know the last two numbers are correct for the interface and the class type (an snmpwalk of 1.3.6.1.4.1.9.9.166.1.15.1.1.14.27729 produces correct values).
It seems the perl script is not parsing the output correctly and returning the string "this" instead of a numerical value?
I have tried changing the "print $ifpol1[13]" to 18 or other values with no luck.
Help? Thx.
Somewhat working now
Meh...I don't know what I was chasing before, but the perl code does indeed work. After stripping out all the variables, I find that it returns good data after all.
One little change I made was to use the 32-bit OID for drops instead of the 64-bit so it'll work with older routers.
But back to the drops per class issue:
For some reason Cacti doesn't put the dropped packets data into a graph correctly *if* Data Source Type is set to type COUNTER in the Data Template. I get zero values for current/ave/max with strange spikes in the millions scale on the graph.
However if I change the Data Source Type to GAUGE, and re-create the graphs, I at least get the same drop per class values in Cacti/RRD as reported by the snmpget. However this value is continually increasing as far as I can tell so the graph isn't really useful. I'll have to see if a clear counters resets this.
Anyone had any success with the Data Source Type set to COUNTER?
Thanks.
One little change I made was to use the 32-bit OID for drops instead of the 64-bit so it'll work with older routers.
But back to the drops per class issue:
For some reason Cacti doesn't put the dropped packets data into a graph correctly *if* Data Source Type is set to type COUNTER in the Data Template. I get zero values for current/ave/max with strange spikes in the millions scale on the graph.
However if I change the Data Source Type to GAUGE, and re-create the graphs, I at least get the same drop per class values in Cacti/RRD as reported by the snmpget. However this value is continually increasing as far as I can tell so the graph isn't really useful. I'll have to see if a clear counters resets this.
Anyone had any success with the Data Source Type set to COUNTER?
Thanks.
Hello,
First of all, sorry for my poor english because I'm french.
I tested these templates for QOS statistics with a cisco router and this is a success. I obtain tree graphs witch represent tree differents COS. Really, I think that is a great job!
But i have a remark. is it possible to have a representation of tree COS (tree classes of the QOS) in the same graph ? It is necessary to have tree differents data source of course ! Thanks for your answers.
Fred
First of all, sorry for my poor english because I'm french.
I tested these templates for QOS statistics with a cisco router and this is a success. I obtain tree graphs witch represent tree differents COS. Really, I think that is a great job!
But i have a remark. is it possible to have a representation of tree COS (tree classes of the QOS) in the same graph ? It is necessary to have tree differents data source of course ! Thanks for your answers.
Fred
Hi wmelick,
I tried your suggestion by changing the Counter to Guage in the Data Type for QoS drops but i still get some weird values. Its not in million any more but it still is in k, which is till not right.
Have you had any success with the QoS drops for each class. Please let me know. Thanks in advance,
Mo
I tried your suggestion by changing the Counter to Guage in the Data Type for QoS drops but i still get some weird values. Its not in million any more but it still is in k, which is till not right.
Have you had any success with the QoS drops for each class. Please let me know. Thanks in advance,
Mo
One thing I noticed is the graph template base value is "1000". I am assuming this is one of the problems for the elevated values. I think the base value should be 1???
When I do set it to one, I get this after clearing the poller cache:
10/09/2006 02:15:02 PM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed "select snmp_query_graph_rrd.snmp_field_name, data_template_rrd.id as data_template_rrd_id from (snmp_query_graph_rrd,data_template_rrd) where snmp_query_graph_rrd.data_template_rrd_id=data_template_rrd.local_data_template_rrd_id and snmp_query_graph_rrd.snmp_query_graph_id= and snmp_query_graph_rrd.data_template_id=55 and data_template_rrd.local_data_id=43"
If I set it back to 1000, it comes back ok.
When I do set it to one, I get this after clearing the poller cache:
10/09/2006 02:15:02 PM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed "select snmp_query_graph_rrd.snmp_field_name, data_template_rrd.id as data_template_rrd_id from (snmp_query_graph_rrd,data_template_rrd) where snmp_query_graph_rrd.data_template_rrd_id=data_template_rrd.local_data_template_rrd_id and snmp_query_graph_rrd.snmp_query_graph_id= and snmp_query_graph_rrd.data_template_id=55 and data_template_rrd.local_data_id=43"
If I set it back to 1000, it comes back ok.
Ok...here is what I have:
I agree with an above comment that there is something not being processed correctly by Cacti.
I generated drops in a default class, and the diff between the previous and current value is 21.
I also ran the qos script before and after to verfiy the rate of change is correct.
As you can see from the above, the router change of drops in the default class matches what the perl script gets.
The resultant graph shows 0.
So what gives? Would a dev mind looking at this? Does anyone have any working examples of a simple COUNTER setup with something like this???
I agree with an above comment that there is something not being processed correctly by Cacti.
I generated drops in a default class, and the diff between the previous and current value is 21.
Code: Select all
previous:
Class-map: class-default (match-any)
471384523 packets, 137315715249 bytes
30 second offered rate 37000 bps, drop rate 0 bps
Match: any
Queueing
Flow Based Fair Queueing
Maximum Number of Hashed Queues 256
(total queued/total drops/no-buffer drops) 0/24768/0
current:
Class-map: class-default (match-any)
471386211 packets, 137316282896 bytes
30 second offered rate 76000 bps, drop rate 8000 bps
Match: any
Queueing
Flow Based Fair Queueing
Maximum Number of Hashed Queues 256
(total queued/total drops/no-buffer drops) 0/24789/0
Code: Select all
previous: debtest:~# /usr/share/cacti/site/scripts/qospol.pl x.x.x.x public 2 get QoSdropperclass 80.class-default
25349
current: debtest:~# /usr/share/cacti/site/scripts/qospol.pl x.x.x.x public 2 get QoSdropperclass 80.class-default
25370
The resultant graph shows 0.
So what gives? Would a dev mind looking at this? Does anyone have any working examples of a simple COUNTER setup with something like this???
Would anyone mind helping me debug the drops?
My graph shows VERY small numbers (1 or 2 drops) when I know there are MANY. I am trying to get the "change" not the total numbers.
So, here is what I have so far:
rrdtool fetch /var/lib/cacti/rra/xyz.rrd LAST
1162224300: 4.6201550388e-02
1162224600: 2.0331337015e-02
1162224900: 1.3377926421e-04
1162225200: 0.0000000000e+00
1162225500: 0.0000000000e+00
1162225800: 0.0000000000e+00
1162226100: 0.0000000000e+00
1162226400: 0.0000000000e+00
Then, I copy and paste the actual poller command used:
/usr/bin/perl /usr/share/cacti/site/scripts/qospol.pl x.x.x.x public 2 get qosstuff.class-default
58513
Which is what the router shows:
(total queued/total drops/no-buffer drops) 24/58513/0
Any ideas?
My graph shows VERY small numbers (1 or 2 drops) when I know there are MANY. I am trying to get the "change" not the total numbers.
So, here is what I have so far:
rrdtool fetch /var/lib/cacti/rra/xyz.rrd LAST
1162224300: 4.6201550388e-02
1162224600: 2.0331337015e-02
1162224900: 1.3377926421e-04
1162225200: 0.0000000000e+00
1162225500: 0.0000000000e+00
1162225800: 0.0000000000e+00
1162226100: 0.0000000000e+00
1162226400: 0.0000000000e+00
Then, I copy and paste the actual poller command used:
/usr/bin/perl /usr/share/cacti/site/scripts/qospol.pl x.x.x.x public 2 get qosstuff.class-default
58513
Which is what the router shows:
(total queued/total drops/no-buffer drops) 24/58513/0
Any ideas?
- Instigater
- Cacti User
- Posts: 141
- Joined: Mon Dec 13, 2004 5:14 pm
- Location: Jurmala, Latvia
I have noticed one bug.
We have configured symetric bandwidth limit. The same class map is shared for input and output, only difference is in direction parameter. This script asumes that class map is used only once per interface that's why we can monitor only one direction.
This sux, I'm trying to make my own script but cisco SNMP agent is a b***. Could someone with a good perl knowledge improve this script?
We have configured symetric bandwidth limit. The same class map is shared for input and output, only difference is in direction parameter. This script asumes that class map is used only once per interface that's why we can monitor only one direction.
This sux, I'm trying to make my own script but cisco SNMP agent is a b***. Could someone with a good perl knowledge improve this script?
anybody help on installing cacti on windows xp
anybody to help me how to install cacti and montior class based qos monitoring from cisco router
it would be helpful if u provide in steps
what all things to done .
it would be helpful if u provide in steps
what all things to done .
QOS
Hi Guys,
I tried importing the files and everything to be fine. I also change permission of qos.xml and qos.pl but when i created a graph, it shows like the one on the screenshot. Also attached is the screenshot when i run debug mode.
Any help would be greatly appreciated.
Thanks and regards.
Melvin
I tried importing the files and everything to be fine. I also change permission of qos.xml and qos.pl but when i created a graph, it shows like the one on the screenshot. Also attached is the screenshot when i run debug mode.
Any help would be greatly appreciated.
Thanks and regards.
Melvin
- Attachments
-
- Screenshot.png (192.55 KiB) Viewed 15839 times
-
- Screenshot-1.png (177.59 KiB) Viewed 15839 times
kenchie,
I ran into this same issue. A couple things to try. A lot of the scripts posted on this message board need to be modified to suite your system.
If you execute the following command as a test via command line you are probably getting no output.
Look at the qospol.pl file. Check that the paths to snmpwalk and snmpget point to where they reside on your machine. For instance, mine are in /usr/local/bin not /usr/bin. You need to replace these paths.
Also, I had to remove the "c" from all the snmpget and snmpwalk statements. I am using snmp version 1. When you try to execute the script with a "1" it will fail because it puts in a 1c. You will get an error like
Hope this helps a little.
I ran into this same issue. A couple things to try. A lot of the scripts posted on this message board need to be modified to suite your system.
If you execute the following command as a test via command line you are probably getting no output.
Code: Select all
perl qospol.pl 10.152.96.65 bmhcpub 1 get Qosdropperclass 80.class-default
Code: Select all
#getting dropsper class
if ($cmd eq 'get' && $cmd1 eq 'QoSdropperclass') {
cindex($get_ix);
my($classdrop) = `/usr/local/bin/snmpget -Os -c $community -v $snmpv $node 1.3.6.1.4.1.9.9.166.1.15.1.1.14.$sindex1.$sindex2`;
$classdrop =~ s/ /./g;
chomp($classdrop);
my(@ifpol1) = split(/\./,$classdrop);
print $ifpol1[13] . "\n";
}
Code: Select all
Invalid version specified after -v flag: 1c
-
- Posts: 24
- Joined: Tue Mar 28, 2006 2:40 am
Does it work on windows
I imported the templates and can't get anything after the associated queries.
Does it work in windows?
Does it work in windows?
I've been looking for the packets/bytes values (e.g., 471386211 packets, 137316282896 bytes) oids for a while now - with no success. Can anybody help me pointing out the oids for these values?heckler40 wrote:Code: Select all
previous: Class-map: class-default (match-any) 471384523 packets, 137315715249 bytes 30 second offered rate 37000 bps, drop rate 0 bps Match: any Queueing Flow Based Fair Queueing Maximum Number of Hashed Queues 256 (total queued/total drops/no-buffer drops) 0/24768/0 current: Class-map: class-default (match-any) 471386211 packets, 137316282896 bytes 30 second offered rate 76000 bps, drop rate 8000 bps Match: any Queueing Flow Based Fair Queueing Maximum Number of Hashed Queues 256 (total queued/total drops/no-buffer drops) 0/24789/0
Who is online
Users browsing this forum: No registered users and 0 guests