The Cisco IOS command `switchport mode dynamic desirable` configures a switch port to use DTP and actively negotiate trunking with a neighboring port. The port becomes a trunk when connected to a port in trunk, dynamic auto, or dynamic desirable mode. section 13.1.1
Remember these operational points:
- Administrative mode describes the configured setting; operational mode describes whether the port currently functions as access or trunk. section 13.3
- Unlike dynamic auto, dynamic desirable actively tries to form a trunk; two dynamic auto ports remain access ports. section 13.1.1
- DTP is considered a security vulnerability, so manually configure port modes and disable negotiation with `switchport nonegotiate` when appropriate. section 13.3
Verify the negotiated result
Configure `SW1 G0/0` with `switchport mode dynamic desirable`, then use `show interfaces g0/0 switchport`. The output should show `Administrative Mode: dynamic desirable` and, when negotiation succeeds, `Operational Mode: trunk`. section 13.1.1
Figure 13.2 SW1 and SW2 negotiate to form a trunk link. SW1 G0/0’s administrative mode is dynamic desirable, and SW2 G0/0’s is dynamic auto. The result is an operational mode of trunk.
Compare dynamic desirable on SW1 with dynamic auto on SW2 to see why DTP produces an operational trunk. section 13.1.1
