Configuring Trunk Ports
The 2960 switch runs the IEEE 802.1q encapsulation method only. To configure trunking on
a Fast Ethernet port, use the interface command
trunk [
parameter
]
. It’s a tad different on
the 3560 switch, and I’ll show you that in the next section.
The following switch output shows the trunk configuration on interface fa0/8 as set to
trunk on:
S1#
config t
S1(config)#
int fa0/8
S1(config-if)#
switchport mode trunk
Table 6.4 lists the trunk commands you can use:
Configuring Trunk Ports
Mode Meaning
access
This places a port into permanent nontrunking mode.
dynamic auto This port state is able to convert to a trunk link if the neighbor
interface is set to become a trunk and can negotiate with DTP.
dynamic desirable Through the use of dynamic trunking protocol (DTP) this port
mode attempts to convert the link into a trunk.
trunk This sets the port state to permanent trunking mode and negotiates
to make the neighbor interface a trunk port as well.
nonegotiate This command can be used with access and trunk modes. It disables
the sending of DTP packets out the interface, thereby disabling
the ability to negotiate the trunk status.
Here is a list of the various trunk modes on a switch port:
switchport mode access
This puts the interface (access port) into permanent nontrunking
mode and negotiates to convert the link into a nontrunk link. The interface becomes a nontrunk
interface regardless of whether the neighboring interface is a trunk interface. This port
would be a dedicated layer-2 port.
switchport mode dynamic auto
This mode makes the interface able to convert the link to a
trunk link. The interface becomes a trunk interface if the neighboring interface is set to trunk
or desirable mode. This is now the default switchport mode for all Ethernet interfaces on all
new Cisco switches.
switchport mode dynamic desirable This one makes the interface actively attempt to convert
the link to a trunk link. The interface becomes a trunk interface if the neighboring interface
is set to trunk, desirable, or auto mode. I used to see this mode as the default on some
older switches, but not any longer. The default is dynamic auto now.
switchport mode trunk This puts the interface into permanent trunking mode and negotiates
to convert the neighboring link into a trunk link. The interface becomes a trunk interface
even if the neighboring interface isn’t a trunk interface.
switchport nonegotiate This prevents the interface from generating DTP frames. You can
use this command only when the interface switchport mode is access or trunk. You must
manually configure the neighboring interface as a trunk interface to establish a trunk link.