cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
17959
Views
0
Helpful
3
Replies

Which SNMP OIDs to get interface counters for multicast/broadcast traffic?

Hi,

does anybody know which MIB/OIDs I can use to query interface counters especially for multicast and broadcast traffic in bits/bytes (not packet count)?

On the cli I only found the command "show vlan id <VLAN> counter", in the MIBs I found the following OIDs but they only query packet counter and not the amount of transfered traffic in bytes:

===

* in *ifXTable* (1.3.6.1.2.1.31.1.1):

** 1.3.6.1.2.1.31.1.1.1.2 (*ifInMulticastPkts*: _The number of packets, delivered by this sub-layer to a higher (sub-)layer, which were addressed to a multicast address at this sub-layer._)

** 1.3.6.1.2.1.31.1.1.1.3 (*ifInBroadcastPkts*: _The number of packets, delivered by this sub-layer to a higher (sub-)layer, which were addressed to a broadcast address at this sub-layer._)

** 1.3.6.1.2.1.31.1.1.1.4 (*ifOutMulticastPkts*: _The total number of packets that higher-level protocols requested be transmitted, and which were addressed to a multicast address at this sub-layer, including those that were discarded or not sent._)

** 1.3.6.1.2.1.31.1.1.1.5 (*ifOutBroadcastPkts*: _The total number of packets that higher-level protocols requested be transmitted, and which were addressed to a broadcast address at this sub-layer, including those that were discarded or not sent._)

** 1.3.6.1.2.1.31.1.1.1.6 (*ifHCInOctets*: _The total number of octets received on the interface, including framing characters. This object is a 64-bit version of ifInOctets._)

** 1.3.6.1.2.1.31.1.1.1.7 (*ifHCInUcastPkts*: _The number of packets, delivered by this sub-layer to a higher (sub-)layer, which were not addressed to a multicast or broadcast address at this sub-layer. This object is a 64-bit version of ifInUcastPkts._)

** 1.3.6.1.2.1.31.1.1.1.8 (*ifHCInMulticastPkts*: _The number of packets, delivered by this sub-layer to a higher (sub-)layer, which were addressed to a multicast address at this sub-layer. This object is a 64-bit version of ifInMulticastPkts._)

** 1.3.6.1.2.1.31.1.1.1.9 (*ifHCInBroadcastPkts*: _The number of packets, delivered by this sub-layer to a higher (sub-)layer, which were addressed to a broadcast address at this sub-layer. This object is a 64-bit version of ifInBroadcastPkts._)

** 1.3.6.1.2.1.31.1.1.1.10 (*ifHCOutOctets*: _The total number of octets transmitted out of the interface, including framing characters. This object is a 64-bit version of ifOutOctets._)

** 1.3.6.1.2.1.31.1.1.1.11 (*ifHCOutUcastPkts*: _The total number of packets that higher-level protocols requested be transmitted, and which were not addressed to a multicast or broadcast address at this sub-layer, including those that were discarded or not sent. This object is a 64-bit version of ifOutUcastPkts._)

** 1.3.6.1.2.1.31.1.1.1.12 (*ifHCOutMulticastPkts*: _The total number of packets that higher-level protocols requested be transmitted, and which were addressed to a multicast address at this sub-layer, including those that were discarded or not sent. This object is a 64-bit version of ifOutMulticastPkts._)

** 1.3.6.1.2.1.31.1.1.1.13 (*ifHCOutBroadcastPkts*: _The total number of packets that higher-level protocols requested be transmitted, and which were addressed to a broadcast address at this sub-layer, including those that were discarded or not sent. This object is a 64-bit version of ifOutBroadcastPkts._)

Best Regards,

Thorsten Steffen

1 Accepted Solution

Accepted Solutions

You can only get the SUM over SNMP for input and output as the example here:

Show vlan counters does not give the information about octects/packets output on a vlan. Also most of the values are 0. Here is the output:

6506-E-1#sh vlan id 51 counters

* Multicast counters include broadcast packets

Vlan Id : 51

L2 Unicast Packets : 16

L2 Unicast Octets : 1834

L3 Input Unicast Packets : 0

L3 Input Unicast Octets : 0

L3 Output Unicast Packets : 0

L3 Output Unicast Octets : 0

L3 Output Multicast Packets : 0

L3 Output Multicast Octets : 0

L3 Input Multicast Packets : 0

L3 Input Multicast Octets : 0

L2 Multicast Packets : 5

L2 Multicast Octets : 405

SNMP however is giving the correct values:

Now SNMP input octects is -

[sj-cse-150]/home/jtamvada> snmpwalk -c public 172.21.56.67

.1.3.6.1.2.1.2.2.1.10.55

IF-MIB::ifInOctets.55 = Counter32: 2239

[sj-cse-150]/home/jtamvada>

Here, SNMP vlaue (2239) is sum of L2 Unicast Octets & L2 Multicast

Octets (1834 + 405).

For the output, you can use 1.3.6.1.2.1.2.2.1.16

There is no mib to get the values one by one. That would be an enhancement request.

View solution in original post

3 Replies 3

Lucien Avramov
Level 10
Level 10

Do you have a show command output showing the counter you want to get?

I was thinking about :

ifInNUcastPkts (.1.3.6.1.2.1.2.2.1.12): These are counts of inbound broadcast and multicast packets.

ifOutUcastPkts (.1.3.6.1.2.1.2.2.1.17):These are counts of outbound broadcast and multicast packets.

===

switch#sh vlan id 123 counters

* Multicast counters include broadcast packets

Vlan Id : 123

L2 Unicast Packets : 13438026979

L2 Unicast Octets : 10893071200183

L3 Input Unicast Packets : 57472951222

L3 Input Unicast Octets : 46852941084144

L3 Output Unicast Packets : 47675105318

L3 Output Unicast Octets : 12501279688609

L3 Output Multicast Packets : 0

L3 Output Multicast Octets : 0

L3 Input Multicast Packets : 0

L3 Input Multicast Octets : 0

L2 Multicast Packets : 408660936

L2 Multicast Octets : 28038366077

===

What I want to get is e.g. the "L2 Multicast Octets" and "L2 Unicast Octets" counter.

Maybe there exist other unicast and multi/broadcast octet interface counters I can get via snmp?

You can only get the SUM over SNMP for input and output as the example here:

Show vlan counters does not give the information about octects/packets output on a vlan. Also most of the values are 0. Here is the output:

6506-E-1#sh vlan id 51 counters

* Multicast counters include broadcast packets

Vlan Id : 51

L2 Unicast Packets : 16

L2 Unicast Octets : 1834

L3 Input Unicast Packets : 0

L3 Input Unicast Octets : 0

L3 Output Unicast Packets : 0

L3 Output Unicast Octets : 0

L3 Output Multicast Packets : 0

L3 Output Multicast Octets : 0

L3 Input Multicast Packets : 0

L3 Input Multicast Octets : 0

L2 Multicast Packets : 5

L2 Multicast Octets : 405

SNMP however is giving the correct values:

Now SNMP input octects is -

[sj-cse-150]/home/jtamvada> snmpwalk -c public 172.21.56.67

.1.3.6.1.2.1.2.2.1.10.55

IF-MIB::ifInOctets.55 = Counter32: 2239

[sj-cse-150]/home/jtamvada>

Here, SNMP vlaue (2239) is sum of L2 Unicast Octets & L2 Multicast

Octets (1834 + 405).

For the output, you can use 1.3.6.1.2.1.2.2.1.16

There is no mib to get the values one by one. That would be an enhancement request.

Review Cisco Networking products for a $25 gift card