breakfixlearn.com

NET-07Networking

STP/RSTP & EtherChannel

Use this when: you add redundant links between switches and need to know which port blocks, how fast it recovers, or how to bundle links.

NET-07 STP/RSTP & EtherChannel cheat sheet. Every table on it is repeated as text below.
Tap the sheet for the full-size image. The text version below is screen-reader friendly.

Text version

Everything on the sheet, as plain HTML: handy for screen readers, copy-paste and search.

How STP picks a loop-free tree

Cisco switches run one tree per VLAN with PVST+ or Rapid PVST+.

StepWhat happens
1. Elect the rootLowest bridge ID wins. A tie on priority goes to the lowest MAC.
2. Root portsEach other switch picks the port with the lowest cost to the root.
3. Designated portsOn each link, the side closest to the root forwards.
4. Block the restLeftover ports become alternate (or backup) and block.

Bridge ID = priority (4 bits; default 32768, in steps of 4096) + extended system ID (12 bits, equal to the VLAN number) + MAC address (48 bits, the tie-breaker).

Port cost

Lower is better. show spanning-tree summary shows which method the switch uses.

SpeedShort (802.1D)Long (802.1t)
10 Mbps1002,000,000
100 Mbps19200,000
1 Gbps420,000
10 Gbps22,000

STP vs RSTP

STPRSTP
Standard802.1D802.1w (Cisco: Rapid PVST+)
Port statesBlocking, listening, learning, forwardingDiscarding, learning, forwarding
Convergence30 to 50 secondsA few seconds

Timers: hello 2 s, forward delay 15 s, max age 20 s.

Configure STP

  • spanning-tree mode rapid-pvst
  • spanning-tree vlan 10 root primary (sets priority 24576, or lower if needed)
  • spanning-tree vlan 20 priority 4096
  • On a PC or server port: spanning-tree portfast and spanning-tree bpduguard enable
  • show spanning-tree vlan 10 shows the root, port roles and costs

EtherChannel: bundle links

ProtocolStartsWaitsWon't form
LACP (IEEE)activepassivepassive + passive
PAgP (Cisco)desirableautoauto + auto
Staticon (no protocol)Forms only with on

Example: interface range g0/1 - 2, channel-group 1 mode active, then interface port-channel 1 and switchport mode trunk.

Bundle rules

  • Up to 8 active members (LACP can hold 8 more on standby)
  • Members must match speed, duplex, access VLAN or trunk VLANs, and native VLAN
  • Never mix LACP and PAgP in one bundle
  • Check with show etherchannel summary (you want SU and P)

Avoid loops

Danger. Use PortFast only on end-host ports. On a switch link it can loop the network.

Caution. Mode on skips negotiation; a mismatch can cause a loop.

Caution. Pick the root on purpose, not by lowest MAC.

Remember

  • The lowest bridge ID is the root
  • BPDU Guard err-disables the port
  • One bundle = one logical STP link

Sources

Go deeper on the blog