Objectives
| # | Objective |
| 1 | Upgrade the spanning-tree mode from classic 802.1D to rapid-pvst on all three switches |
| 2 | Verify RSTP is active โ observe the new port states (Discarding, Learning, Forwarding) and roles (Alternate, Backup) |
| 3 | Open the RSTP Convergence Simulator โ step through the proposal/agreement handshake that makes RSTP fast |
| 4 | Configure Edge ports (PortFast) on all four PC-facing access ports across both switches |
| 5 | Enable BPDU Guard on Edge ports โ individually and globally โ and verify with show commands |
| 6 | Simulate a link failure and observe RSTP's sub-second reconvergence โ contrast with STP's 30โ50 second delay |
| 7 | Knowledge check โ RSTP port states, roles, proposal/agreement and Edge port behaviour |
Key Concepts
| Concept | What it means |
| Rapid-PVST+ | Cisco's per-VLAN implementation of RSTP (802.1w). Replaces classic PVST+ (802.1D) with sub-second convergence using the proposal/agreement mechanism. |
| RSTP Port States | Three states: Discarding (replaces Blocking+Listening), Learning, Forwarding. Eliminates the 15s Listening state entirely. |
| RSTP Port Roles | Adds Alternate Port (backup to Root Port โ instant failover) and Backup Port (backup Designated Port on a shared segment). Root Port and Designated Port remain. |
| Proposal/Agreement | The key to RSTP speed. A switch proposes a port as Designated. The downstream switch syncs all non-edge ports to Discarding and replies with Agreement. The port moves directly to Forwarding โ no timers. |
| Edge Port | RSTP term for a PortFast port โ a port connected to a single end device that never participates in topology changes. Goes straight to Forwarding, never sends Topology Change Notifications. |
| BPDU Guard | Err-disables an Edge port that receives any BPDU. Prevents rogue switches from being connected to access ports. Must be recovered manually with shutdown/no shutdown. |
| Topology Change | In RSTP, a TC is signalled directly with a special BPDU flag โ no longer requires the root bridge to relay it. Faster MAC table flushing, faster reconvergence. |
Topology โ Two Switches, Four PCs, One Trunk
| Device | Port | Role | RSTP State |
| SW1 (Root) | Gi0/1 | Designated | Forwarding |
| SW1 | Gi0/2 | Designated | Forwarding |
| SW1 | Gi0/0 | Edge (PortFast) | Forwarding (Edge) |
| SW2 | Gi0/1 | Root Port | Forwarding |
| SW2 | Gi0/2 | Alternate | Discarding |
| SW2 | Gi0/0 | Edge (PortFast) | Forwarding (Edge) |
SW3 connects via Gi0/2 on both SW1 and SW2. One of SW2's uplinks becomes the Alternate Port.
Key Commands
| Command | Purpose |
| spanning-tree mode rapid-pvst | Enable RSTP (Rapid-PVST+) globally โ replaces 802.1D |
| show spanning-tree | Verify RSTP mode, port states and roles |
| show spanning-tree detail | Show RSTP-specific fields: port type, topology change counts |
| spanning-tree portfast | Configure an Edge port on an interface |
| spanning-tree portfast default | Enable PortFast on all non-trunk access ports globally |
| spanning-tree bpduguard enable | Enable BPDU Guard per-interface |
| spanning-tree portfast bpduguard default | Enable BPDU Guard globally on all PortFast ports |
| show spanning-tree interface Gi0/0 portfast | Verify PortFast status on a specific port |
| show errdisable recovery | Show err-disabled ports and auto-recovery settings |
| debug spanning-tree events | Watch live STP/RSTP events in real time |
After enabling RSTP on all switches, click โก RSTP Simulator to step through the proposal/agreement handshake that gives RSTP its speed โ compared side by side with classic STP.
spanning-tree mode rapid-pvst is a global command โ it affects all VLANs on that switch simultaneously. Both ends of a link should run the same STP mode for optimal behaviour.