Upon completion of this chapter, you will be able to perform the following tasks: Describe redundancy in switched network Describe how STP works Configure Spanning tree protocol
Trang 1Module 04 LAN Switching
Chapter 15 Spanning Tree Protocol
Trang 2 Upon completion of this chapter, you will be able to
perform the following tasks:
Describe redundancy in switched network
Describe how STP works
Configure Spanning tree protocol
Optional STP features
Trang 3Redundant Topology
Redundant topology eliminates single points of failure
Redundant topology causes broadcast storms, multiple frame copies, and MAC address table instability problems
Segment 1
Segment 2
Trang 5Multiple Frame Copies
• Host X sends an unicast frame to Router Y
• Router Y MAC Address has not been learned by
either Switch yet
• Router Y will receive two copies of the same frame
Trang 6MAC Database Instability
• Host X sends an unicast frame to Router Y
• Router Y MAC Address has not been learned by either
Port 0 Port 1
Trang 7MAC Database Instability
• Host X sends an unicast frame to Router Y
• Router Y MAC Address has not been learned by either Switch yet
• Switch A and B learn Host X MAC address on port 0
• Frame to Router Y is flooded
• Switch A and B incorrectly learn Host X MAC address on port 1
Port 0 Port 1
Trang 8 Complex topology can cause multiple loops to occur
Layer 2 has no mechanism to stop the loop
Server/host
Workstations
Loop
Loop Loop Multiple Loop Problems
Broadcast
Trang 9Solution: Spanning-Tree Protocol
Provides a loop free redundant network topology by
placing certain ports in the blocking state
Block
x
Trang 10Spanning-Tree Operations
Spanning-Tree Operations
• One root bridge per network
• One root port per nonroot bridge
• One designated port per segment
Trang 11Switch Y Default priority 32768 (8000 hex)
Spanning-Tree Protocol Root Bridge Selection
Spanning-Tree Protocol Root Bridge Selection
BPDU
BPDU = Bridge protocol data unit
(default = sent every 2 seconds) Root bridge = Bridge with the lowest bridge ID Bridge ID = Bridge priority + bridge MAC address
In the example, which switch has the lowest bridge ID?
Trang 12Switch Y Default priority 32768 MAC 0c0022222222
10baseT
Nondesignated port (B) Designated port (F)
Trang 13Spanning-Tree Protocol Path Cost
Link Speed Cost (reratify IEEE spec) Cost (previous IEEE spec) -
Trang 14Switch Y MAC 0c0022222222 Default priority 32768
Can you figure out:
• What is the root bridge?
• What are the designated, nondesignated, and root ports?
100baseT
100baseT
Spanning-Tree:
Trang 15Switch Y MAC 0c0022222222 Default priority 32768
Can you figure out:
• What is the root bridge?
• What are the designated, nondesignated, and root parts?
• Which are the forwarding and blocking ports?
Root port (F)
Trang 16Blocking (20 sec) Listening
(15 sec) Learning
(15 sec) Forwarding
Spanning-Tree Port States
Spanning-tree transitions each port
through several different state:
Trang 17Reacting to Network Change
Reacting to Network Change
Switch Y MAC 0c0022222222 Default priority 32768
Trang 18Switch Y MAC 0c0022222222 Default priority 32768
x
Reacting to Network Change
Trang 19Key Issue: Time to Convergence
• Convergence occurs when all the switch
and bridge ports have transitioned to
either the forwarding or blocking state
• When network topology changes,
switches and bridges must recompute
the Spanning-Tree Protocol, which
disrupts user traffic
Trang 20Optional to SPT Features
Etherchanel
• Etherchanel provides a way to prevent STP
convergence from being needed when only one
port or cable failed
•Etherchanel combines from 2 to 8 parallel
ethernet trunks between the same pair of
switches-> etherchanel
•STP treats an etherchanel as a single link
Trang 21Optional to SPT Features
Portfast
• Portfast allows a switch to place a port
in forwading state immediately when the
port becomes physically active.
• The port should not connect to bridges,
switches or other STP speaking device
•The Cisco BPDU Guard feature, if
enable, tell the switch to disable Protfast
port of BPDU is received on those ports.
Trang 22Rapid Spanning Tree
Pt-pt link
Share link
Edge link
Trang 23 Upon completion of this chapter, you will be able to
perform the following tasks:
Describe redundancy in switched network
Describe how STP works
Configure Spanning tree protocol
Optional STP features