The landmarks before the election
The CCNA works with Rapid PVST+, Cisco’s per-VLAN implementation of Rapid STP (RSTP, once IEEE 802.1w and now folded into IEEE 802.1Q-2022). Each VLAN gets its own tree, so one switch can be root for VLAN 30 and a plain transit switch for VLAN 40.
The bridge ID that drives the election has two parts. The first is a priority: a configured value in steps of 4096 (default 32768) plus the VLAN number, the system ID extension. The second is the switch MAC address. A switch at default priority advertises 32798 in VLAN 30; set spanning-tree vlan 30 priority 24576 and it advertises 24606.
Cisco describes the role and state model in Understand Rapid Spanning Tree Protocol (802.1w).
This is topic 2.5 in both v1.1 and v2.0; in v2.0 the verb becomes configure and BPDU filter drops out (what changes in v2.0). PortFast, BPDU guard and the other protections live in the Rapid PVST+ and EtherChannel study area.
The election, in the order the switch runs it
Root bridge
Lowest bridge ID wins: compare priority first, and only on a priority tie compare MAC addresses. Ports on the root normally all become designated.
Root port on each other switch
Lowest root path cost wins, the sum of port costs from this switch back to the root. A switch has exactly one root port per VLAN.
Tie on root path cost
Compare the sender bridge ID in the BPDUs received, lowest wins. Still tied: lowest sender port ID (port priority, default 128, then port number).
Designated port on each segment
The switch advertising the lowest root path cost onto the segment owns the designated port, which forwards.
Everything else
A port that is neither root nor designated discards. RSTP calls it alternate when its better BPDUs come from another switch, backup when they come from its own switch on a shared segment.
A worked triangle
Port costs behind the arithmetic
| Link speed | Short cost |
|---|---|
| 10 Mb/s | 100 |
| 100 Mb/s | 19 |
| 1 Gb/s | 4 |
| 10 Gb/s | 2 |
Long costs (802.1t) use different values. CCNA material uses short costs; newer Catalyst IOS XE releases may default to long, so check show spanning-tree summary before you trust a total.
Roles and states in Rapid PVST+
- Root port
- This switch’s best path to the root bridge. Forwards.
- Designated port
- The best sender of BPDUs onto a segment. Forwards.
- Alternate port
- A discarding port that offers a second path to the root through a different switch.
- Backup port
- A discarding port that offers a second connection to a segment this switch already serves.
- Port states
- Rapid PVST+ keeps three: discarding, learning and forwarding. Roles say what a port is for; states say what it does with frames right now.
Frames on STP root bridge and roles
Several frames carry a small topology table. Work the bridge IDs and path costs on paper first, then compare your role assignments with the options.
Practice frames written by our editors for study, not Cisco items. The 200-301 exam itself mixes multiple choice, drag-and-drop and lab-style items.
Frame 001 of 006 · 0 answered · 0 ok
Keys
1–5 or A–E pick an option (on choose-N frames they toggle; then Check answer) · ← → previous / next frame · ↑ ↓ move in the frame list
- Frame 001 of 006
In Rapid PVST+, which port role is responsible for forwarding traffic toward the root bridge?
Pick an option. The verdict shows here; open the note under any option to see why.
Note on A
Correct: each non-root switch has one root port, the port with the lowest path cost to the root bridge, and it forwards toward the root.
Note on B
A designated port forwards away from the root onto a segment, and every port on the root bridge itself is designated.
Note on C
A backup port is a discarding spare for a designated port on the same shared segment, so it forwards nothing.
Note on D
An alternate port is a discarding standby path to the root that takes over if the root port fails.
Best answer: A · why
Rapid PVST+ uses four port roles. The root port is the best path toward the root bridge, and each non-root switch has exactly one. Designated ports forward onto each segment, away from the root. Alternate ports are blocked backup paths to the root. Backup ports are blocked spares for a designated port on the same shared segment. Only root and designated ports forward.
- Frame 002 of 006
In Rapid PVST+, which port state takes the place of the 802.1D blocking and listening states?
Pick an option. The verdict shows here; open the note under any option to see why.
Note on A
Listening is one of the 802.1D states that RSTP removed, so a port running Rapid PVST+ never shows it.
Note on B
Correct: RSTP folds the 802.1D disabled, blocking and listening states into one discarding state and keeps learning and forwarding.
Note on C
Blocking is the old 802.1D name; in Rapid PVST+ the same non-forwarding behavior is called discarding.
Note on D
A disabled port is administratively down; RSTP treats it as discarding, so disabled is not the state that replaced blocking and listening.
Best answer: B · why
802.1D STP has five port states: disabled, blocking, listening, learning and forwarding. RSTP (802.1w, now part of 802.1Q), which Rapid PVST+ runs per VLAN, keeps three: discarding, learning and forwarding. Discarding covers every state that neither forwards frames nor learns MAC addresses, which is why blocking and listening disappear.
- Frame 003 of 006
Three switches run Rapid PVST+ for VLAN 10. The table shows the bridge priority each one advertises for VLAN 10 and its base MAC address. Which statement correctly describes the root bridge election?
Switch Advertised priority (VLAN 10) Base MAC address SW1 32778 (32768 + 10) 0011.2233.4400 SW2 32778 (32768 + 10) 0011.2233.4401 SW3 28682 (28672 + 10) 0011.2233.44ff Pick an option. The verdict shows here; open the note under any option to see why.
Note on A
Correct. The bridge ID is priority first, then MAC, and the lowest wins. SW3’s 28682 beats 32778, so its higher MAC never matters.
Note on B
The MAC address is only the tiebreaker. It would decide between SW1 and SW2, but SW3’s lower priority settles the election first.
Note on C
This inverts the rule. Lower values win at every step of the bridge ID comparison, for priority and for MAC alike.
Note on D
28682 is the configured 28672 (a multiple of 4096) plus the VLAN 10 system ID extension, so it is a normal advertised value.
Best answer: A · why
Spanning tree elects as root the switch with the lowest bridge ID. On Cisco switches running per-VLAN spanning tree, the bridge ID is the configured priority (a multiple of 4096, default 32768) plus the VLAN number as the system ID extension, followed by the MAC address. The priority part is compared first; the MAC only breaks a tie. SW3 was set to 28672, so it advertises 28682 for VLAN 10, lower than the 32778 of the two switches left at the default, and it becomes root even though its MAC is the highest. Source: IEEE 802.1Q-2022 (RSTP) and Cisco’s Rapid Spanning Tree (802.1w) document.
- Frame 004 of 006
SW1 is the root bridge for VLAN 20, and all switches use short (802.1D-1998) port costs. Based on the links in the table, which port does SW3 select as its root port?
Link Speed Port cost SW1 Gi0/2 to SW3 Fa0/1 100 Mb/s 19 SW1 Gi0/1 to SW2 Gi0/1 1 Gb/s 4 SW2 Gi0/2 to SW3 Gi0/2 1 Gb/s 4 Pick an option. The verdict shows here; open the note under any option to see why.
Note on A
Spanning tree does not count hops. It adds port costs, and the direct 100 Mb/s link costs 19 against 8 through the two gigabit links.
Note on B
Port ID is the last tiebreaker and is used only when root path cost and sender bridge ID tie. Here the costs differ.
Note on C
Speed matters only through the cost it implies. The comparison is total root path cost, which here happens to favor the gigabit path.
Note on D
Correct. Through SW2 the costs add up to 4 + 4 = 8, which beats the 19 of the single 100 Mb/s link, so Gi0/2 is the root port.
Best answer: D · why
A non-root switch picks as root port the port with the lowest root path cost: the sum of the costs of the receiving ports along the path to the root. With short costs, 100 Mb/s costs 19 and 1 Gb/s costs 4. SW2 reaches SW1 with cost 4 and advertises it; SW3 adds the cost of its own Gi0/2 (4), for 8. The direct Fa0/1 path costs 19. Lowest cost wins, so Gi0/2 becomes the root port and Fa0/1 will usually end up discarding as an alternate port. Hop count and port speed alone are never compared. Source: IEEE 802.1D-1998 path costs; Cisco’s Rapid Spanning Tree (802.1w) document.
- Frame 005 of 006
SW2 has two parallel links to SW1, the root bridge, and both give the same root path cost. SW2 Gi0/1 connects to SW1 Gi0/2, and SW2 Gi0/2 connects to SW1 Gi0/1. Every port uses the default port priority of 128, and port IDs follow interface numbering. Which SW2 port becomes the root port?
Pick an option. The verdict shows here; open the note under any option to see why.
Note on A
The tiebreaker is the port ID of the sender, the upstream switch, not the number of the local port that receives the BPDU.
Note on B
Correct. Cost and sender bridge ID tie, so the sender port ID decides. SW1 Gi0/1 has the lower ID, and SW2 Gi0/2 receives from it.
Note on C
Both BPDUs come from SW1, so the sender bridge ID is identical on both links and cannot break the tie.
Note on D
Spanning tree allows a single root port per VLAN. The other link is discarding unless both are bundled into an EtherChannel.
Best answer: B · why
When candidate root ports tie on root path cost, the switch compares, in order, the sender bridge ID and then the sender port ID (port priority plus port number of the upstream switch) from the received BPDUs. Lower wins each time. Here both links come from SW1, so the sender bridge ID ties. The sender port IDs are 128.1 (SW1 Gi0/1) and 128.2 (SW1 Gi0/2), so the SW2 port wired to SW1 Gi0/1, which is Gi0/2, becomes the root port. Its own lower local number does not help Gi0/1. Source: IEEE 802.1Q-2022 (RSTP) and Cisco’s Rapid Spanning Tree (802.1w) document.
- Frame 006 of 006
In a Rapid PVST+ network, SW3 has two uplinks that lead to the root bridge through two different upstream switches. Gi0/1 is the root port. Gi0/2 receives BPDUs from the other upstream switch that offer a worse path to the root than Gi0/1, and it is discarding. Which role does Gi0/2 have?
Pick an option. The verdict shows here; open the note under any option to see why.
Note on A
A backup port receives better BPDUs from its own switch on a shared segment. Gi0/2 hears a different switch, so it is not a backup port.
Note on B
The designated port on that link is the upstream switch’s port, which sends the better BPDUs. Gi0/2 only receives them, so it is not designated.
Note on C
Correct. A port that receives better BPDUs from another switch but is not the root port is an alternate port, ready to take over as root port.
Note on D
A disabled port is administratively down or not operating. Gi0/2 is up, receiving BPDUs and held as a backup path, so it is not disabled.
Best answer: C · why
RSTP (now part of IEEE 802.1Q) assigns each port a role. The root port is the best path to the root; the designated port is the best sender on each segment. A port that loses both contests gets one of two discarding roles. If the better BPDUs it hears come from another switch, it is an alternate port: a ready replacement path to the root that can become root port quickly if the current one fails. If they come from the same switch on a shared segment, it is a backup port, a spare for that switch’s own designated port. Gi0/2 hears a different upstream switch, so it is alternate. Source: Cisco’s Rapid Spanning Tree (802.1w) document.
Spanning tree questions in brief
Is a lower bridge priority better?
Yes. Every comparison in spanning tree prefers the lower value: bridge ID, root path cost, sender bridge ID and port ID.
Why do two parallel links between the same switches still lose one link?
Spanning tree sees two paths and blocks one. Bundling the links into an EtherChannel makes them a single logical port, which is where the LACP vs PAgP modes come in.
Can I choose which switch becomes root?
Yes. Lower its priority for that VLAN in a step of 4096, for example spanning-tree vlan 30 priority 24576, and it wins the comparison before any MAC address is read. Do the same with the next-lowest value on the switch you want as backup.
References
- [1]Cisco: Understand Rapid Spanning Tree Protocol (802.1w)Checked October 29, 2026.
- [2]Cisco Learning Network: CCNA v1.1 exam topicsChecked October 29, 2026.
- [3]Cisco Learning Network: CCNA v2.0 exam topicsChecked October 29, 2026.