Root port, root bridge (primary/secondary) and other port names

2.5 Interpret basic operations of Rapid PVST+ Spanning Tree Protocol

2.5.a Root port, root bridge (primary/secondary), and other port names

What is Spanning Tree Protocol (STP)?

In a Layer 2 switched network, switches are often connected with redundant links to provide fault tolerance.
However, redundant links can create loops, and loops can cause broadcast storms, multiple frame copies, and MAC address table instability — which can bring down the network.

To prevent this, Cisco switches use a Spanning Tree Protocol (STP) that logically blocks some ports to break the loop — while keeping the network fully available if a link fails.


⚡ Rapid PVST+ (Rapid Per VLAN Spanning Tree Plus)

Rapid PVST+ is Cisco’s improved and faster version of STP.

It stands for:

  • Rapid → Based on IEEE 802.1w (Rapid Spanning Tree Protocol – RSTP)
  • PVST+ → Per VLAN Spanning Tree Plus (Cisco feature that runs one instance of STP per VLAN)

So, Rapid PVST+ = RSTP (802.1w) + PVST+ (per VLAN instance)

This means:

  • Each VLAN has its own spanning tree instance
  • Rapid PVST+ can converge faster (in 1–2 seconds instead of 30–50 seconds like traditional STP)
  • It is backward compatible with older STP versions

🧭 Basic Operation of Rapid PVST+

The main goal of Rapid PVST+ is to:

  1. Select one Root Bridge (the main switch)
  2. Find the best path to the Root Bridge
  3. Block redundant paths to prevent loops
  4. React quickly to link failures (fast convergence)

Let’s go through the key components that the exam expects you to know.


🔹 Step 1: Root Bridge Selection

Every switch in the network starts by assuming it is the Root Bridge.
They all send Bridge Protocol Data Units (BPDUs) — special messages that help switches compare and elect the Root Bridge.

Bridge ID (BID)

Each switch has a unique Bridge ID, made up of:

  • Bridge Priority (default = 32768)
  • Extended System ID (VLAN ID)
  • MAC Address of the switch

Formula:

Bridge ID = Bridge Priority + VLAN ID + MAC Address

Root Bridge Election Rules

  • The switch with the lowest Bridge ID becomes the Root Bridge.
  • If priorities are equal, the switch with the lowest MAC address wins.
  • You can manually set priority to make a switch the root.

Example (in IT context):
If you want a core switch to be the Root Bridge for VLAN 10, you can configure:

Switch(config)# spanning-tree vlan 10 root primary

🟢 Primary and Secondary Root Bridge

  • Primary Root Bridge:
    The switch that actually becomes the Root Bridge (lowest Bridge ID).
  • Secondary Root Bridge:
    A backup switch that is configured with a slightly higher priority than the primary.
    It will take over if the primary fails.

Configuration:

Switch(config)# spanning-tree vlan 10 root secondary

Cisco automatically sets its priority to the next best value (4096 higher than the primary).


🔹 Step 2: Identify Port Roles (in Rapid PVST+)

Each port in the STP topology is assigned a role based on its function in reaching the Root Bridge.

1. Root Port (RP)

  • Exists on every non-root switch.
  • It is the port with the lowest cost path to reach the Root Bridge.
  • There is only one Root Port per switch.
  • It is always in a forwarding state.

Example in IT context:
A distribution switch chooses the uplink port to the core switch (Root Bridge) as its Root Port.


2. Designated Port (DP)

  • Exists on every network segment (link between switches or between switch and host).
  • The port that has the lowest path cost to the Root Bridge on that segment becomes the Designated Port.
  • It forwards traffic toward and away from that segment.
  • Each segment has only one Designated Port.

3. Alternate Port

  • A backup to a Root Port.
  • It provides an alternate path to the Root Bridge in case the Root Port link fails.
  • It is in a discarding (blocking) state during normal operation.
  • It can quickly transition to forwarding if the active path fails (this is part of RSTP’s fast convergence).

4. Backup Port

  • A backup to a Designated Port on the same switch and same segment (rare scenario, like two ports on the same switch connected to the same hub).
  • It is also in a discarding state during normal operation.
  • Used only if the Designated Port fails.

5. Disabled Port

  • A port that is administratively shut down or not participating in STP.
  • It does not send or receive BPDUs.

🧩 Summary of Port Roles in Rapid PVST+

Port RoleDescriptionState
Root Port (RP)Best path to the Root BridgeForwarding
Designated Port (DP)Forwards frames for its segmentForwarding
Alternate PortBackup for Root PortDiscarding
Backup PortBackup for Designated Port (same switch/segment)Discarding
Disabled PortNot participating in STPDiscarding

⚙️ Step 3: Port States in Rapid PVST+

Rapid PVST+ simplifies port states compared to original STP.

RSTP StateOld STP StateDescription
DiscardingBlocking/ListeningPort does not forward frames or learn MAC addresses
LearningLearningPort learns MAC addresses but does not forward frames
ForwardingForwardingPort sends and receives frames normally

🚀 RSTP Fast Convergence

One of the main advantages of Rapid PVST+ is fast convergence.

In traditional STP (802.1D):

  • It could take 30–50 seconds to detect a failure and restore connectivity.

In Rapid PVST+ (802.1w):

  • Convergence happens in 1–2 seconds.
  • It uses handshakes instead of timers.
  • Ports can quickly move to the Forwarding state using the Proposal/Agreement mechanism.

🧠 Key Points for the CCNA Exam

  1. Rapid PVST+ = RSTP (802.1w) + PVST+ (per VLAN instance)
  2. Root Bridge = switch with lowest Bridge ID
  3. Primary Root Bridge and Secondary Root Bridge can be configured for redundancy.
  4. Root Port = best path toward Root Bridge (one per non-root switch)
  5. Designated Port = forwarding port on each segment
  6. Alternate/Backup Ports = standby ports in discarding state
  7. States: Discarding → Learning → Forwarding
  8. Convergence = 1–2 seconds (faster than traditional STP)
  9. BPDUs are used to share topology information.

✅ Quick Recap Diagram (Conceptually)

[Root Bridge]
   |
   | (Designated Port)
[Non-root Switch]
   |
   | (Root Port)
[Access Switch]
  • The Root Bridge has Designated Ports on all active links.
  • Other switches have Root Ports toward the Root Bridge.
  • Redundant links have Alternate Ports in discarding state.

Leave a Reply

Your email address will not be published. Required fields are marked *

Buy Me a Coffee