Configuring a Trunk Link
To configure an 802.1Q trunk, perform this task in privileged mode:
Task
Step 1
Configure an 802.1Q trunk.
Step 2
Verify the trunking configuration.
This example shows how to configure an 802.1Q trunk and how to verify the trunk configuration:
Console> (enable) set trunk 2/9 desirable dot1q
Port(s) 2/9 trunk mode set to desirable.
Port(s) 2/9 trunk type set to dot1q.
Console> (enable) 07/02/1998,18:22:25:DTP-5:Port 2/9 has become dot1q trunk
Console> (enable) show trunk
Port
--------
2/9
Port
--------
2/9
Port
--------
2/9
Port
--------
2/9
Console> (enable)
Defining the Allowed VLANs on a Trunk
When you configure a trunk port, all VLANs are added to the allowed VLANs list for that trunk.
However, you can remove VLANs from the allowed list to prevent traffic for those VLANs from passing
over the trunk.
When you first configure a port as a trunk, the set trunk command always adds all VLANs to the allowed
Note
VLAN list for the trunk, even if you specify a VLAN range (any specified VLAN range is ignored). To
modify the allowed VLANs list, use a combination of the clear trunk and set trunk commands to
specify the allowed VLANs.
To define the allowed VLAN list for a trunk port, perform this task in privileged mode:
Task
Step 1
Remove VLANs from the allowed VLANs list for
a trunk.
Step 2
(Optional) Add specific VLANs to the allowed
VLANs list for a trunk.
Step 3
Verify the allowed VLAN list for the trunk.
Software Configuration Guide—Catalyst 4000 Family, Catalyst 2948G, Catalyst 2980G, Releases 6.3 and 6.4
11-6
Chapter 11
Mode
Encapsulation
-----------
-------------
desirable
dot1q
Vlans allowed on trunk
---------------------------------------------------------------------
1-1005
Vlans allowed and active in management domain
---------------------------------------------------------------------
1,5,10-32,101-120,150,200,250,300,400,500,600,700,800,900,1000
Vlans in spanning tree forwarding state and not pruned
---------------------------------------------------------------------
5,10-32,101-120,150,200,250,300,400,500,600,700,800,900,1000
Configuring VLAN Trunks on Fast Ethernet and Gigabit Ethernet Ports
Command
set trunk mod_num/port_num [on | desirable |
auto | nonegotiate] dot1q
show trunk [mod_num/port_num]
Status
Native vlan
------------
-----------
trunking
1
Command
clear trunk mod_num/port_num vlans
set trunk mod_num/port_num vlans
show trunk [mod_num/port_num]
78-12647-02