Cisco CBWFQ monitoring

Templates, scripts for templates, scripts and requests for templates.

Moderators: Developers, Moderators

Post Reply
itzsen
Posts: 2
Joined: Mon Jun 11, 2007 1:07 pm

What MIB are needed to graph the CBWFQ graphs

Post by itzsen »

I am new to Cacti, please bear my ignorance.

I can successfully map the CPU, memory, interface utilization using Cacti. Now i am trying to map the QoS configured on the WAN routers. I have used this script multiple times before and it worked. This time i get see the policy-maps but when i try to graph it, i get 'RRD data file does not exist'. This router is managed by ATT when they enable the MIB (only on request). I am suspecting its a MIB not configured correctly on the routers. Can someone please tell me what MIBs need to be enabled for the QoS scripts.

-Senthil
maxstoner
Posts: 16
Joined: Fri Dec 30, 2005 9:27 am

MIBS needed

Post by maxstoner »

Hi,
You need this MIBs here:

"config" => ".1.3.6.1.4.1.9.9.166.1.7.1.1.1", # list of all configured QoS classes
"config_index" => ".1.3.6.1.4.1.9.9.166.1.5.1.1.2", # cbQosConfigIndex
"int_index" => ".1.3.6.1.4.1.9.9.166.1.1.1.1.4", # cbQosIfIndex
"policy_direction" => ".1.3.6.1.4.1.9.9.166.1.1.1.1.3", # cbQosPolicyDirection
"int_name" => ".1.3.6.1.2.1.31.1.1.1.1",
"int_description" => ".1.3.6.1.2.1.31.1.1.1.18",
"class_traffic" => ".1.3.6.1.4.1.9.9.166.1.15.1.1.11",
"pre_class_traffic" => ".1.3.6.1.4.1.9.9.166.1.15.1.1.7",
"drop_class_traffic" => ".1.3.6.1.4.1.9.9.166.1.15.1.1.18",
"drop_class_byte" => ".1.3.6.1.4.1.9.9.166.1.15.1.1.17",
"pre_class_byte" => ".1.3.6.1.4.1.9.9.166.1.15.1.1.6",
"class_byte" => ".1.3.6.1.4.1.9.9.166.1.15.1.1.10",
magzz69
Posts: 20
Joined: Thu Jul 24, 2008 3:22 am

Post by magzz69 »

Hi!!

I monitor some routers and I need to know the traffic of my QOS. I have found this two OID :

cbQosCMPostPolicyBitRate 1.3.6.1.4.1.9.9.166.1.15.1.1.11
And
cbQosCMPrePolicyBitRate 1.3.6.1.4.1.9.9.166.1.15.1.1.7

But, when I compare with my other plugin which display the traffic in and out of my router I see that the traffic of my qos is just for the traffic_out.

I'm more interested in knowing what is the qos' traffic of my router for the traffic_in!

If there is another OID i'm interested because I haven't found it!

Thanks a lot,
magzz69
Posts: 20
Joined: Thu Jul 24, 2008 3:22 am

Post by magzz69 »

up? :)
magzz69
Posts: 20
Joined: Thu Jul 24, 2008 3:22 am

Post by magzz69 »

When I use this OID

service-policy [ output | input ] "policy-map-name"
1.3.6.1.4.1.9.9.166.1.6.1.1.1

I've got this result :

1063 = STRING: "WAN"
1073 = STRING: "ETH"

Which show us the traffic in/out.
But how can I use this values for having the QOS of my router for the traffic IN and out.
Dom...
Posts: 29
Joined: Tue Aug 21, 2007 1:36 pm

Post by Dom... »

Same problem, I use also the mib
"class_traffic" => ".1.3.6.1.4.1.9.9.166.1.15.1.1.11" to do SNMP request to a router, but I have not found if it is for the traffic IN or OUT (of the class), or the sum.
magzz69
Posts: 20
Joined: Thu Jul 24, 2008 3:22 am

Post by magzz69 »

.1.3.6.1.4.1.9.9.166.1.15.1.1.11 is the cbQosCMPostPolicyBitRate so it's the traffic of your qos' class in bytes/sec

But We don't know if it's traffic in or out and also how to have the 2 traffics...
:(
dvdlubbe
Posts: 12
Joined: Thu Aug 06, 2009 4:44 pm

Post by dvdlubbe »

I've been using this template for over a year now and it's working great.
However, recently I encountereed some strange problems that took me quite some time to solve. I thought I might post it here so others might benefit from it. Anyway, this is what happened:

I added a new policy-map to a tunnel-interface on one of my routers and afterwards I noticed that I was not able to create the graphs for it in Cacti. Everything seemed to work fine (I could see the classes etc.), but when I wanted to add the graphs, the RRD files simply weren't created at all.

The really weird part was that I already had some cbwfq-graphs running for the very same router (a different policy on a different interface) and those graphs kept working fine. However, when I removed one of those older graphs and tried to recreate it, the same thing happened: the RRD wasn't generated anymore. :o

After some investigating I found out the following:

The new policy-map I added looked like this:

Code: Select all

Policy-map QOS
 class GOLD
 bandwidth XXX
 class SILVER
 bandwidth XXX
 class BRONZE
 bandwidth XXX
 class class-default
 bandwidth XXX

policy-map SHAPE-QOS
 class class-default
  shape average XXXXXX
  service-policy QOS

interface Tunnel1
 service-policy output SHAPE-QOS
When I manually tried the script I saw this:

Code: Select all

perl /usr/local/share/cacti/scripts/cbwfq.pl [IP] [COMM] query
1953.1957:GOLD-QOS-Tunnel1
1953.1965:SILVER-QOS-Tunnel1
1953.1977:BRONZE-QOS-Tunnel1
1953.2007:class-default-QOS-Tunnel1
1953.2013:class-default-QOS-Tunnel1
Turned out that the reason it didn't work was that "class-default-QOS-Tunnel1" appeared twice in the list. The second occurrence should have been named "class-default-SHAPE-QOS-Tunnel1

The solution couldn't have been simpler: just remove and then re-apply the QOS policy within the SHAPE-QOS policy:

Code: Select all

policy-map SHAPE-QOS
 class class-default
  no service-policy QOS
  service-policy QOS
When I tested this time, the proper name was applied:

Code: Select all

perl /usr/local/share/cacti/scripts/cbwfq.pl [IP] [COMM] query
1953.2013:class-default-SHAPE-QOS-Tunnel1
1953.2069:GOLD-QOS-Tunnel1
1953.2077:SILVER-QOS-Tunnel1
1953.2089:BRONZE-QOS-Tunnel1
1953.2119:class-default-QOS-Tunnel1
From that moment on the graphs worked without a glitch!

...so it might just be a cisco-bug or something, I don't know.
Anyway, maybe some of you can put the above info to good use. 8)

Regards,
User avatar
G0dSmack
Cacti User
Posts: 85
Joined: Wed Nov 12, 2008 10:25 am
Contact:

Post by G0dSmack »

Anyone been able to do this using a pure xml snmp based query? I was thinking about trying it, but it doesnt seem like it is going to be easy. Just thought I would ask before I spent too much time. This script works for me, but I would like to get more stats out of the queries.

Thanks!
eugenef
Posts: 6
Joined: Sat Mar 07, 2009 5:22 am
Contact:

Post by eugenef »

G0dSmack wrote:Anyone been able to do this using a pure xml snmp based query? I was thinking about trying it, but it doesnt seem like it is going to be easy. Just thought I would ask before I spent too much time. This script works for me, but I would like to get more stats out of the queries.

Thanks!
I have also the same idea in mind after I found out that existing solutions posted here do not work for me :( However I end up modifying one of the templates here for making it working for me.

G0dSmack, In case you already did a script using pure SNMP, please share it here :)

I'm attaching what I did for myself for making template working.
Attachments
Cisco_QoS.zip
(6.33 KiB) Downloaded 3889 times
shd
Cacti User
Posts: 96
Joined: Mon Apr 09, 2007 1:33 pm
Location: Nizhnevartovsk, Russia

Post by shd »

eugenef wrote:I'm attaching what I did for myself for making template working.
made some fixes:
* now it works with newer versions of net-snmp
* combined bytes/drops in one graph
Attachments
Cisco_QoS.zip
(6.04 KiB) Downloaded 4829 times
CentOS 64-bit, 20Gb RAM, 8xCPU, some virtual datastore. 600+ hosts, 200k+ datasources, avg polltime 45 sec
eugenef
Posts: 6
Joined: Sat Mar 07, 2009 5:22 am
Contact:

Post by eugenef »

shd wrote:
eugenef wrote:I'm attaching what I did for myself for making template working.
made some fixes:
* now it works with newer versions of net-snmp
* combined bytes/drops in one graph
hey,

i was also thinking to put drops/bytes on one graph however I afraid it will be hard to see drops when traffic is huge and you have only several drops.

what is new in net-snmp? :)
shd
Cacti User
Posts: 96
Joined: Mon Apr 09, 2007 1:33 pm
Location: Nizhnevartovsk, Russia

Post by shd »

eugenef wrote:i was also thinking to put drops/bytes on one graph however I afraid it will be hard to see drops when traffic is huge and you have only several drops.
i think it's not so important to see actual form of drop graphs. what's more important is to see, if there are any drops are made. so a one pixel red line and numeric info at the bottom of graph would be more helpful. also, when there are a dozen of class-maps at one router, there are too many graphs, so why don't we cut them to half?
eugenef wrote:what is new in net-snmp? :)
net-snmp wants to have all parameters before host address. at least in my net-snmp on freebsd 7.2

also, i tried to show configured rate for each class-map in each policy, but there are lots of complications like dealing with parent maps, so i stuck halfway through implementing. well, may be i will make this work later.
CentOS 64-bit, 20Gb RAM, 8xCPU, some virtual datastore. 600+ hosts, 200k+ datasources, avg polltime 45 sec
hassanhija
Posts: 14
Joined: Wed Nov 26, 2008 3:58 am

Post by hassanhija »

magzz69 wrote:.1.3.6.1.4.1.9.9.166.1.15.1.1.11 is the cbQosCMPostPolicyBitRate so it's the traffic of your qos' class in bytes/sec

But We don't know if it's traffic in or out and also how to have the 2 traffics...
:(
hello guys,

Iam searching in this field ( monitoring both Inbound and Outbound for COS in the same graph ) where the main templete shows the outbound and the mib 1.3.6.1.4.1.9.9.166.1.15.1.1.11 related to cbQosCMPostPolicyBitRate ,
So i beileve that i have to create a custom graph templetes to calculate in traffic with the out traffic , in the first test i failed :oops: , so i wish to provide me with any idea regarding this field .

the second thing is how to consolidate different data sources in the same graph to draw the COS classifiers in the same graph??????


regards,
saidat
boots
Cacti User
Posts: 55
Joined: Wed Jan 07, 2004 4:59 am
Location: Melbourne Australia

Post by boots »

Does this script support nested policy maps?

Also, has anyone got a template to show shaping?

Cheers

Boots
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest