Assigning a native VLAN ID to a trunk interface
Prerequisites
At least one defined VLAN.
Procedure
-
Switch to configuration context with the command
config
. -
Switch to the trunk interface to which you want to assign the native VLAN ID with the command
interface
. -
Assign the native VLAN ID with the command
vlan trunk native
. If tagging is required, use the commandvlan trunk native tag
. -
Allow traffic tagged with the native VLAN ID to be transported by the trunk using the command
vlan trunk allowed.
Example
This example assigns native VLAN ID
20 to trunk interface
1/1/2.
switch# config switch(config)# vlan 20 switch(config-vlan-20)# exit switch(config)# interface 1/1/2 switch(config-if)# vlan trunk native 20
This example assigns native VLAN ID
40 to trunk interface
1/1/5, enables tagging, and allows traffic with VLAN ID 40 to be transported by the trunk.
switch# config switch(config)# vlan 40 switch(config-vlan-40)# exit switch(config)# interface 1/1/5 switch(config-if)# vlan trunk native 40 tag switch(config-if)# vlan trunk allow 40