Last Updated on August 1, 2021 by Admin
Which IOS interface configuration commands are required to configure a switch port to actively negotiate to be an 802.1Q trunk port that, when active, will send packets destined for VLAN 3 untagged? (Choose three.)
- switchport mode trunk
- switchport trunk dot1q 3
- switchport native vlan 3
- switchport trunk mode dot1q
- switchport mode dynamic auto
- switchport trunk native vlan 3
- switchport trunk encapsulation dot1q
Entering the IOS commands switchport mode trunk and switchport trunk encapsulation dot1q in interface configuration mode will allow a switch port to actively negotiate to be an 802.1Q trunk port. Setting the trunk native VLAN to 3 with the command switchport trunk native vlan 3 will allow VLAN 3 traffic to be sent and received untagged over the trunk port.
The command switchport mode trunk instructs DTP to actively negotiate to be a trunk if the other side is set to trunk, desirable, or auto.
Use the following steps to configure a port as an 802.1Q trunk:
1. Enter the interface configuration. switch(config)# interface interface-id
2. Configure the port to using 802.1Q encapsulation. switch(config-if)# switchport trunk encapsulation dot1q
3. Configure the port as a trunk port. switch(config-if)# switchport mode trunk
4. (Optional) Set the native VLAN number. switchport trunk native vlan number
If the native VLAN is changed as above, it must be changed on both ends of the link. Failure to do so will cause the link to not be successfully built because the native VLAN numbers must match. When left to the default (VLAN 1) the issue takes care of itself. If a native VLAN mismatch occurs, it will be reflected in the debug command output of one of the switches, as shown below.
2009 Aug 11 16:36:11 %SPNTREE-2-RX_IQPVIDERR:Rcvd pvid_inc BPDU on 1Q port 0/2 vlan3
2009 Aug 11 16:36:11 %SPNTREE-2-TX_BLKPORTPVID:Block 0/2 on xmitting vlan 1 for inc peer vlan
2009 Aug 11 16:36:11 %SPNTREE-2-RX_BLKPORTPVID:Block 0/2 on rcving vlan 3 for inc peer vlan 1
Note: Trunking modes can be configured as access, dynamic desirable, dynamic auto, trunk, and nonegotiate. If both sides are set to auto, no negotiations will occur.
The switchport allowed vlan command is also valid for configuring dot1q trunks, but is not required. By default, all VLANs are allowed on the trunk.
Layer 2 Technologies
Configure and verify trunking