Spanning Tree Protocol Study Guide
Evolution of STP Basics Evolution of STP What is STP? (Spanning Tree Protocol) – Eliminates loops at layer 2 topology
There are many varieties of STP...[pg 120]
- DEC STP
- 802.1D
- Common Spanning Tree (CST)
- Per VLAN Spanning Tree Plus+
- Rapid STP (RSTP)/IEEE 802.1w
- Multiple Spanning Tree(MST)
- PVRST+
STP
- STP initially converges on a logically loop-free network topology.
- Elects one root bridge
- Selects the root port on all nonroot bridges
- Selects the designated port on each segment
STP Steps (cont)
- Elects One Root Bridge
- The protocol uses a process to elect a root bridge
- Only one bridge acts as the root bridge in a given network per VLAN
- On the root bridge, all ports act as designated ports
- Switch with lowest priority parameter is elected as root
STP Step 2 (cont)
- Selects the Root Port on All Non-root Bridges
- The protocol establishes one root port on each nonroot bridge.
- The root port is the lowest-cost path from the nonroot bridge to the root bridge
Step 3
- Selects Designated Port on Each Segment
- On each segment, STP establishes one designated port on the bridge that has the lowest path cost to the root bridge
- The switch primarily chooses a designated port as the least-cost path to the root bridge
- In the event of a tie, the bridge ID acts as the tiebreaker
Port Roles
The are four roles of ports under STP 1)Root 2)Designated Port 3)Non-designated Port 4)Disabled
STP Port states:
- Blocking
- Listening
- Learning
- FOrwarding
- Disabled
RSTP Ports States:
- Discarding
- Learing
- Forwarding
The discarding state of RSTP is equivalent to the Blocking and Listening states of STP
RSTP Port Roles
- Root: The port going toward the root bridge
- Designated: There is one on each segment. It receives the frames from the root port.
- Alternate: A port that is blocked but is an alternate path to the root bridge. Would go into forwarding stat if root port goes down.
- Backup: A port that is blocked because it is a redundant link to the root bridge and has the higher port ID. Would go into forwarding stat if root port goes down.
- Disabled: Plays no role in spanning-tree
RSTP relies on the variables of Link type and Edge ports to achieve fast convergence.
The link types are:
- Point-to-point: full-duplex port
- Shared: half duplex port
An edge port is directly connected to an end point and are allowed to transistion directly into forwarding. This is like portfast except that in an edge port receives a BPDU it will automatically become a normal spanning-tree port.
RSTp Topology Change Mechanism
When an RSTP bridge detects a topology change it performs the following actions.
RSTP bridge starts the TC While timer with value equal to twice the hello time for nonedge designated ports and root port. RSTP bridge actively informs the rest of the bridges in the network of topology change. RSTP bridge flushes MAC addresses associated with all nonedge ports. If the TC While timer is running on a port, the BPDU’s sent out of that port have the TC bit set. While the timer is active the bridge sends BPDU even on the root port.
Bridge Identifier for PVRST+
Bridge Priority: A 4-bit field still used to carry bridge priority. In values of 4096. Default value is 32,768. Extended System ID: 12-bit field carrying the VID for PVST+. Mac Address: 6-byte field with MAC address of a single switch.
Cisco STP Default Config
(PVST+) PerVLAN Spanning Tree Plus -- default STP mode (PVRST+) PerVLAN Rapid Spanning Tree Plus (MST) Multiple Spanning Tree
PortFast
Spanning Tree Portfast causes an interface configured as a layer 2 access port to enter the forwarding state immediately. Conf t int fa 0/1 spanning-tree portfast
confirm with show spanning-tree interface Fastethernet 0/1.
Config the Basic Parameters of PVRST+ conf t spanning-tree mode rapid-pvst spanning-tree vlan 2 root primary spanning tree- vlan 3 root secondary
Multiple Spanning Tree
MST extends the IEEE 802.1w RST algorithm to multiple spanning trees. The main purpose of MST is to reduce the total number of spanning-tree instances.