This document describes the behavioural difference between Aggregation Services Routers 1000 series (ASR1K) and Integrated Services Routers 4000 series (ISR4K) routers in accounting for input and output packets when a sub-interface is configured with encapulation dot1q even though they run the same IOS-XE software.
Contributed by Venkat Ramasamy Kannan, Cisco TAC Engineer.
Cisco recommends that you have knowledge of ASR1K and ISR4K routers along with basic vlan and sub-interface tagging concepts.
This document is not restricted to specific software and hardware versions.
However, The information in the document is created using the below hardware.
ASR 1006 running IOS-XE 3.13.3S
ISR 4321 running IOS-XE 3.16.0C
The information in this document was created from the devices in a specific lab environment. All of the devices used in this document started with a cleared (default) configuration. If your network is live, make sure that you understand the potential impact of any command.
Default Behaviour - ASR 1006
no ip address
encapsulation dot1Q 1115 native
ip address 192.168.2.1 255.255.255.0
Input and Output Counters
R-ASR1006-2#show vlans dot1q 1115 Total statistics for 802.1Q VLAN 1115: 4021 packets, 241260 bytes input <-- counter is very low (and frozen)
10 packets, 420 bytes output <-- counter is very low (and frozen)
0 oversubscription packet drops
However these counters seem to be wrong because this is the only sub-interface under the physical interface, and there is a huge mismatch in the values.
NR-ASR1002-2#sh int gigabitEthernet 0/0/1
GigabitEthernet0/0/1 is up, line protocol is up
2429325386 packets input, 1438158021764 bytes, 0 no buffer
2429263775 packets output, 1438124149520 bytes, 0 underruns
Default Behaviour - ISR4321
! interface GigabitEthernet0/0/1 no ip address load-interval 30 negotiation auto ! interface GigabitEthernet0/0/1.3503 encapsulation dot1Q 1115 native ip address 184.108.40.206 255.255.255.252 !
Input and Output Counters
ISR4321-1#show vlans dot1q 3503 Total statistics for 802.1Q VLAN 3503: 141584463 packets, 101578951916 bytes input 142482559 packets, 45106997466 bytes output
Values between physical interface gig0/1 and the subinterface gig0/1.3503 match.
Reason for the Behavioural Difference
The reson for this behavioural difference between ASR1K and ISR4K even though they run the same IOS-XE is that, when encap dot1q 10 native is configured, the stats are grabbed from the data-plane. However in ASR1K, the stats are grabbed from the Shared Port Adaptor (SPA) hardware and the SPA is not as intelligent as the data-plane processor, so it doesn't know how to count untagged packets against a specific vlan.
In order to make the ASR1K work like the ISR4K, you should count the packets at the data-plane level like the ISR4k.The way to do that is to configure this on the ASR.
Warning: This command must be used with caution. Once this is enabled, the SPA stops doing the packet classification. So, if the router is already in an over-subscribed scenario, any packet (high or low priority, because the packets are not classified anymore) could be dropped