SNMP counters (ifInOctets, ifOutOctets, ifHCInOctets and ifHCOutOctets) do not count the Ethernet Header (14 bytes)

This article describes the issue of the SNMP counters (ifInOctets, ifOutOctets, ifHCInOctets, and ifHCOutOctets) not counting the Ethernet Header (14 bytes).

As per RFC 2665, the four OID’s (ifInOctets, ifOutOctets, ifHCInOctets, and ifHCOutOctets) should be adding the framing characters for the interface. However, in Juniper’s implementation, the traffic statistics that are retrieved via SNMP do not include the 14 byte Ethernet header overhead.

For example:

When a 1000 byte frame is transmitted, the SNMP statistics for the Ethernet interface will be 982 bytes sent/received; that is (1000bytes -14 bytes (DMAC+SMAC+Ethertype) -4 bytes (FCS) = 982).

As per RFC 2665 (chapter 3.2.7):

“ifInOctets: the number of octets in valid MACframes received on this interface, including the MAC header and FCS”

This is working as designed, as per the Juniper hardware specification. The four OID octets are not included in the total number of octets that are transmitted out of the interfaces, which are configured under M, T and MX- series router platforms. EX switches adhere to RFC 2665

About the author


Leave a Comment