02-28-2011 03:32 PM - edited 03-06-2019 03:48 PM
I have a question on if the Native VLAN needs to be allowed on the trunk port? Below is an example:
switch A
vlan 310
name MAN
!
vlan 333
name NATIVE
interface Port-channel2
description * MAN EtherChannel *
switchport trunk encapsulation dot1q
switchport trunk native vlan 333
switchport trunk allowed vlan 310
switchport mode trunk
interface GigabitEthernet1/0/2
description UPLINK
switchport trunk encapsulation dot1q
switchport trunk native vlan 333
switchport trunk allowed vlan 310
switchport mode trunk
speed 100
duplex full
channel-group 2 mode active
interface GigabitEthernet2/0/2
description UPLINK
switchport trunk encapsulation dot1q
switchport trunk native vlan 333
switchport trunk allowed vlan 310
speed 100
duplex full
channel-group 2 mode active
07-28-2017 09:04 PM - edited 07-18-2020 02:16 PM
I've seen a lot of responses to this, some recent some old. Many have good information, some have misleading or wrong information.
First - my summarized recommendation to the original question:
More details....
To properly understand native VLANs, you have to consider the industry at the time IEEE defined the 802.1q standard (1998).
Largely, most switches... ahem "most non-Cisco switches" were just dumb switches. they took a frame, if it was a "known unicast" it would forward to the appropriate port but all BUM (Broadcast / Unknown Unicast / Multicast) traffic would flood the incoming frame out all interfaces except the one it came in on. The concept of VLANs was not known, so all that flooding would happen to ALL ports. 802.1q allowed this to be curtailed, but only for those switches that understood how to read it.
Cisco had "ISL", which was one of the early implementations of VLANs, but ISL was proprietary. (Fast aside: the professor that wrote the formal academic paper conceptualizing VLANs, actually differentiated the LANs using "colors" rather than numbers. This was 1982-1988. Here's the original research paper.)
So, 802.1q has a different EtherType. In order to allow compatibility between switches that understood 802.1q and switches that did not understand 802.1q, IEEE devised the concept of a "native" VLAN - the one VLAN that would be sent with a standard DIX-II EtherType (aka what we now colloquially call "untagged"). This would allow hosts connected to such switches, to still communicate on the network
These days, those kinds of switches are rare in corporate LANs (though D-Link, Linksys, NetGear, and similar really really cheap consumer-grade switches are still something this primitive). For certain, all routers (ASR1k, ASR9k, ISR, etc) and most (all?) ASAs and FirePowers can be configured to be VLAN-aware, and all Cisco Catalyst, MetroEthernet, IndustrialEthernet, and Nexus switches understand native VLAN tagging really well. But, the untagged native VLAN capability is still there.
Weylin
PS - example when a native VLAN must be untagged:
The Cisco LWAP 1810W and 1815W are APs that are wall-mounted, and provide wired RJ45 ports in addition to wireless 802.11n. VLANs to apply to the RJ45 ports come on the AP's uplink port as tagged VLAN(s), and the management of the AP itself (including the CAPWAP-encapsulated WiFi traffic) is an untagged VLAN. In this case, the port on the switch that the AP connects to, that port would have a VLAN to manage the AP, which may/may not be the same as the VLAN to manage the switch (for my network, switch and LWAP management are on separate VLANs/subnets), and client VLANs and FlexConnect VLANs would be 3rd (and 4th, and...) VLANs. The trunk between the switch and the router would has a native VLAN, but since access-layer switches tend to only have a global setting for native VLAN tagging, and since I must have an untagged native VLAN to the AP, I therefor must also have an untagged native VLAN to the router. In order to show protection against doubly-tagged frames, use a native VLAN on the switch/router link that purpose-implemented explicitly for native VLAN.
PPS - in case you're wondering, I run a large university campus, with about a dozen-and-a-half Catalyst 6807s. Most of them support a handful of buildings. A few of them handle a lot of small buildings; the largest has 95 buildings on it (all of them small buildings). With that, I have 95 native VLANs defined, one for each building, all of them tagged and none of them in the "trunk allowed" list.
PPPS - this is a typical router port config on my network (the downstream switch is a Catalyst 3850-24P-L)
Cat6807#show run | inc vlan dot1q
vlan dot1q tag native
Cat6807#
Cat6807#
Cat6807#
Cat6807# show run vlan 2800
Building configuration...
Current configuration : 48 bytes
!
vlan 2800
name CompSci_Native-no_IP
end
Cat6807#
Cat6807#
Cat6807#
Cat6807# show run int vlan 2800
Building configuration...
Current configuration : 247 bytes
!
interface Vlan2800
description Native VLAN to Computer Science faculty offices. VLAN INTERFACE SHUTDOWN BY DESIGN
no ip address
no ip redirects
no ip unreachables
no ip proxy-arp
shutdown
end
Cat6807#
Cat6807#
Cat6807#
Cat6807# show run int t7/2
Building configuration...
Current configuration : 612 bytes
!
interface TenGigabitEthernet7/2
description CompSci Faculty Workstation Switch Gig1/1/1
switchport
switchport trunk native vlan 2800
switchport mode trunk
switchport trunk allowed vlan 20,150,152,153,2000,2200,2400,2800
switchport nonegotiate
platform qos trust cos
udld port aggressive
service-policy type lan-queuing input c6800-48p-sfp-qos-ingress-policy
service-policy type lan-queuing output c6800-48p-sfp-qos-egress-policy
end
Cat6807#
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide