Skip to content

2.0 Switching and Network Access

Spanning Tree Protocol Practice Questions

STP root election, port roles, and PortFast/BPDU guard.

Author-reviewed by LabFabric · 8 September 2026 · Report a content issue

One solved question, so you can see how these are marked

For one VLAN, all switches advertise the same STP bridge-priority value. Which switch wins the root election?

The switch with the lowest bridge ID (priority plus MAC address)

STP elects the lowest bridge ID. With equal priority values for the same VLAN, the bridge MAC portion breaks the tie. In per-VLAN output, the displayed priority can include the VLAN's extended system ID, so do not treat every displayed value as a platform-independent factory constant.

Every question in the set below is marked like this. The answers stay hidden until you pick one.

Explore STP and try the root bridge lab
All 9 Spanning Tree Protocol questions in this set

Answers and explanations appear when you work through the set above.

  1. For VLAN 10, show spanning-tree lists the direct uplink as Altn BLK and a longer uplink as Root FWD. Why is VLAN 10 using the longer path?

    • A port on the direct path is in the blocking state
    • The access switch has no default gateway configured
    • VTP pruning removed the VLAN from the direct link
    • The direct link is using half duplex
  2. Which command lets an administrator see the current STP role and state of each port on a switch?

    • show spanning-tree
    • show interfaces trunk
    • show vlan brief
    • show mac address-table
  3. An administrator wants a switch to win VLAN 1's root election ahead of peers with their current priorities unchanged. Which change makes MAC address tie-breaking unnecessary?

    • Set its VLAN 1 bridge priority lower than every peer's priority
    • Disable STP on every other switch in the topology
    • Assign that switch the lowest VLAN ID
    • Increase the port cost on all of that switch's uplinks
  4. On a non-root switch, which port is chosen as the root port for a given VLAN?

    • The port with the highest port number
    • The port facing the root bridge with the lowest cost path
    • Any port that is currently in the forwarding state
    • The port with the highest bandwidth regardless of path cost
  5. A junior engineer connects a switch that creates a Layer 2 loop to a PortFast edge port. Why can traffic be disrupted immediately after link-up?

    • PortFast disables MAC address learning on the port
    • PortFast places the port into forwarding immediately, before normal STP convergence can block the new redundant path
    • PortFast automatically forms an EtherChannel with any connected device
    • PortFast forces the port into the blocking state permanently
  6. Which STP protection should be enabled on PortFast edge ports so a received BPDU places the port into an error-disabled state?

    • BPDU Guard
    • Root Guard
    • Loop Guard
    • UplinkFast
  7. A switch is using the short STP path-cost method. What automatic cost does it assign to a 1-Gbps Ethernet interface?

    • 100
    • 19
    • 4
    • 2
  8. An engineer runs show spanning-tree and sees a port listed with role "Altn" and state "Blocking". What does this mean?

    • The port has failed and needs to be replaced
    • The port is an alternate path to the root bridge and is intentionally not forwarding to prevent a loop
    • The port is the designated port for that segment
    • The port is not participating in STP at all
  9. Two access switches have a direct link, but VLAN 10 traffic between them follows the distribution layer because the direct link is alternate/discarding. Which statement correctly explains this topology?

    • STP always selects the path with the fewest physical switches between the two endpoints
    • STP builds a loop-free tree toward the elected root using path cost and tiebreakers; it does not optimize every endpoint pair for hop count
    • The direct link cannot carry BPDUs because only distribution switches participate in STP
    • An alternate port proves the direct cable or transceiver has failed