DETAILED STEPS
PurposeCommand or Action
Entersthe global configurationmode.configureterminal
Example:
Switch# configure terminal
Step 1
Specifiesthe port tobe configured,and entersinterface
configurationmode.
interfaceinterface-id
Example:
Switch(config)# interface
Step 2
gigabitethernet1/0/1
Configuresthe interfaceas a VLANtrunk port.switchportmode trunk
Example:
Switch(config-if)# switchport mode trunk
Step 3
(Optional)Configures the list of VLANs allowed on the trunk.switchporttrunk allowed vlan {add |all |except
|none|remove}vlan-list
Step 4
Thevlan-list parameter is eithera singleVLAN number from1
to4094 or a range of VLANs described by two VLAN numbers,
Example:
Switch(config-if)# switchport trunk allowed
thelower one first, separated by a hyphen. Do not enter any
spacesbetween comma-separatedVLAN parameters or in
hyphen-specifiedranges.
vlan remove 2
AllVLANs areallowed by default.
Returnsto privileged EXEC mode.end
Example:
Switch(config)# end
Step 5
Verifiesyour entries in the Trunking VLANs Enabled field of the
display.
showinterfaces interface-id switchport
Example:
Switch# show interfaces gigabitethernet1/0/1
Step 6
(Optional)Saves your entriesin theconfiguration file.copyrunning-config startup-config
Step 7
Example:
Switch# copy running-config startup-config
Toreturn to the default allowed VLAN list of all
VLANs,use the no switchporttrunk allowedvlan
interfaceconfiguration command.
Note
Catalyst 2960-XR Switch VLAN Configuration Guide, Cisco IOS Release 15.0(2)EX1
70 OL-29440-01
Configuring VLAN Trunks
Configuring an Ethernet Interface as a Trunk Port