Navigation
Guide That Contains This Content
[+] Expand All
[-] Collapse All

    Accounting of the Layer 2 Overhead Attribute in Interface Statistics

    On MX Series routers, you can configure the physical interface and logical interface statistics to include the Layer 2 overhead size (header and trailer bytes) for both ingress and egress interfaces. Both the transit and total statistical information are computed and displayed for each logical interface. This functionality is supported on 1-Gigabit and 10-Gigabit Ethernet interfaces on Dense Port Concentrators (DPCs) and Modular Port Concentrators (MPCs). Also, this feature is supported on 10-Gigabit Ethernet interfaces on MX Series routers with MPC4E. To enable the Layer 2 overhead bytes to be counted in the interface statistics at the PIC level, you must use the account-layer2-overhead statement at the [edit chassis fpc slot-number pic pic-number] hierarchy level.

    You can also enable the Layer 2 overhead bytes for computation in the logical interface statistics by configuring the account-layer2-overhead (value | <ingress bytes | egress bytes>) statement at the [edit interface interface-name unit logical-unit-number] hierarchy level. If you configure this capability, all the Layer 2 header details (Layer 2 header and cyclic redundancy check [CRC]) based on the Layer 2 encapsulation configured for an interface are calculated and displayed in the physical and logical interface statistics for ingress and egress interfaces in the output of the show interfaces interface-name commands. For physical and logical interfaces, the Input bytes and Output bytes fields under the Traffic statistics section in the output of the show interfaces interface-name <detail | extensive> command include the Layer 2 overhead of the packets. For physical and logical interfaces, the Input rate and Output rate fields under the Traffic statistics section in the output of the show interfaces interface-name <media | statistics> command include the Layer 2 overhead of the packets. For logical interfaces, the values for the newly added Egress accounting overhead and Ingress accounting overhead fields display the Layer 2 overhead size for transmitted and received packets respectively.

    The input and output octets at the physical or logical interface configured on the PIC includes all the Layer 2 headers. All the logical interfaces on the PIC, including the ae and the non-ae interfaces, are processed for Layer 2 overhead accounting for the arriving and exiting packets. This method of operation impacts the transit statistics that are primarily used for subscriber accounting and billing purposes in customer networks.

    Table 1 lists the adjustment bytes that are counted based on the encapsulation on the logical interface over the Ethernet interface, when you enable accounting of Layer 2 overhead in interface statistics at the PIC level. The values for the adjustment bytes that are listed for all types of encapsulation are the same for DPCs and MPCs, with the only exception being for the VLAN CCC adjustment value. On DPCs, the VLAN CCC adjustment value is –4 bytes and on MPCs, the VLAN CCC adjustment value is +4 bytes.

    Table 1: Adjustment Bytes for Logical Interfaces over Ethernet Interfaces

    Encapsulation Type on Logical InterfacesNumber of Adjustment BytesDescription

    Ethernet DIXv2 (IP datagrams over Ethernet)

    18

    Untagged (includes CRC)

    Ethernet DIXv2 (IP datagrams over Ethernet)

    22

    Single-tagged (includes CRC)

    Ethernet DIXv2 (IP datagrams over Ethernet)

    26

    Double-tagged (includes CRC)

    VLAN Bridge

    4

    CRC

    VLAN CCC

    4

    CRC

    VLAN TCC

    18

    Untagged (includes CRC)

    VLAN TCC

    22

    Single-tagged (includes CRC)

    VLAN TCC

    26

    Double-tagged (includes CRC)

    VLAN VPLS

    4

    CRC

    Guidelines for Configuring the Computation of Layer 2 Overhead in Interface Statistics

    Keep the following points in mind when you configure the feature to compute Layer 2 overhead in interface statistics:

    • When you configure a native VLAN ID on a logical interface, the Layer 2 header adjustment for input statistics is different for tagged and untagged packets. For such interfaces, if you configure the setting to account for Layer 2 overhead, incorrect statistics might be displayed.
    • An untagged packet is considered as a tagged packet and an additional 4 bytes are appended to the counter values displayed in the output of the show interface command.
    • The computed statistics might not be completely accurate in scenarios where the packets are dropped after they have been included in the interface statistics, but before the packets reach the destination.
    • Label-switched interface (LSI) statistics on the ingress direction of interfaces do not include the Layer 2 overhead bytes because this functionality of accounting Layer 2 overhead is not supported for such LSI interfaces.
    • Layer 2 overhead accounting is not supported for inline service (si) interfaces.
    • The total statistics of physical interfaces do not indicate the complete Layer 2 adjusted statistics. This behavior occurs because the total statistics count is the sum of transit and local statistics. Only the transit statistics are adjusted for Layer 2 and the local statistics are not adjusted for Layer 2.
    • Statistics on ae interfaces are calculated in the same manner as non-ae interfaces.
    • Adjustment bytes are applicable only for transit statistics that are displayed for logical interfaces.
    • For physical interfaces, the adjustment bytes for transit traffic and the non-adjusted bytes for local or protocol-specific traffic are combined and displayed in the output of the show interfaces command. (Segregation is not possible.)
    • If you configure the account-layer2-overhead ( value | <ingress bytes | egress bytes>) statement at the [edit interface interface-name unit logical-unit-number] hierarchy level, the Layer 2 overhead computation might not work correctly for logical interfaces over an aggregated Ethernet (ae) interface that is created across two different line cards having different forwarding hardware (such as MPCs and DPCs). This method of processing applies only for VLAN circuit cross-connect (CCC) encapsulation.
    • The Layer 2 overhead bytes in interface statistics are saved across a unified ISSU or a graceful Routing Engine switchover (GRES) operation.

    Published: 2013-08-01