Professional Documents
Culture Documents
in Depth
• IEEE 802.1D
• A loop-prevention protocol
• Allows L2 devices to
communicate with each
other to discover physical
loops in the network.
• Algorithm that creates a
loop-free logical topology.
• STP creates a tree
structure of loop-free
leaves and branches that
spans the entire Layer 2
network.
Rick Graziani graziani@cabrillo.edu 5
L2 Loops
Bridge ID
Without the
Extended
System ID
Bridge ID with
the Extended
System ID
• Bridges use the concept of cost to evaluate how close they are to
other bridges.
• Used to create the loop-free topology .
• Originally, 802.1D defined cost as 1 billion/bandwidth of the link in
Mbps.
– Cost of 10 Mbps link = 100
– Cost of 100 Mbps link = 10
– Cost of 1 Gbps link = 1
• Running out of room for faster switches including 10 Gbps Ethernet
Rick Graziani graziani@cabrillo.edu 18
Path Cost – Revised Spec (Non-Linear)
Cost (Revised IEEE Cost (Previous IEEE
Link Speed
Spec) Spec)
10 Gbps 2 1
1 Gbps 4 1
100 Mbps 19 10
10 Mbps 100 100
• IEEE modified the most to use a non-linear scale with the new values of:
– 4 Mbps 250 (cost)
– 10 Mbps 100 (cost) • You can change the path cost by
– 16 Mbps 62 (cost) modifying the cost of a port.
– 45 Mbps 39 (cost) • Exercise caution when you do this!
– 100 Mbps 19 (cost) • BID and Path Cost are used to develop
– 155 Mbps 14 (cost) a loop-free topology .
– 622 Mbps 6 (cost) • Coming very soon!
– 1 Gbps 4 (cost)
– 10 Gbps 2 (cost)
Rick Graziani graziani@cabrillo.edu 19
Five-Step STP Decision Sequence
STP Convergence
Step 1 Elect one Root Bridge
Step 2 Elect Root Ports
Step 3 Elect Designated Ports
Who wins?
• Use this command to view the information on the other four switches.
Rick Graziani graziani@cabrillo.edu 24
What is the BID of this switch? Who is the Root?
25
My BID is My BID is
32769.0005.5E0D.9315 32769.0060.47B0.5850
My BID is My BID is
32769.0003.E461.46EC 32769.0001.964E.7EBB
I win!
32769.0001.C945.A573
32769.0005.5E0D.9315 32769.0060.47B0.5850
32769.0003.E461.46EC 32769.0001.964E.7EBB
BPDUs
sent/relayed BPDU
every two
seconds.
BPDU BPDU
BPDU BPDU
My BID is
32768.0001.C945.A573 I’m Who wins?
the root!
My BID is
My BID is 32768.0060.47B0.5850
32768.0005.5E0D.9315 I’m the root!
I’m the root!
My BID is
My BID is
32768.0003.E461.46EC
32768.0001.964E.7EBB
I’m the root!
I’m the root! I win!
Root Bridge
• Now that the Root War has been won, switches move on to
selecting Root Ports.
• A bridge’s Root Port is the port closest to the Root Bridge.
• Bridges use the cost to determine closeness.
• Every non-Root Bridge will select one Root Port!
• Specifically, bridges track the Root Path Cost, the cumulative
cost of all links to the Root Bridge.
Rick Graziani graziani@cabrillo.edu 36
Determining (Electing) the Root Port
Path Cost
BPDU BPDU
Cost=0+19=19 Cost=0+19=19
19
19
Root Bridge
0
0
BPDU 19 0 BPDU
Cost=0
Cost=0+19=19
Path Cost
BPDU BPDU
Cost=0+19=19 Cost=0+19=19
19
19
Root Bridge
0
0
BPDU 19 0 BPDU
Cost=0
Cost=0+19=19
Path Cost
Path Cost
BPDU BPDU
Cost=4+19=23
Cost=4+19=23
19
19
BPDU
BPDU
Cost=19 Cost=19 0
0
19 0
Root Bridge
BPDU BPDU
Cost=4+19=23
Cost=4+19=23
19
19
BPDU
BPDU
Cost=19 Cost=19 0
0
19 0
Root Bridge
BPDU
Cost=4+19=23
BPDU
BPDU
Cost=19+19=38
Cost=19
19
23 23
19
0 Root Bridge
19
0
19
BPDU
0
Cost=4+19=23
19+4=23 19+4=23
23+4=27 23+4=27
19+19=38 19+19=38
19 19+4=23
19+4=23 19
19+4=23 19+4=23
0
19 0
0 Root Bridge
23 19
23 23 0
19 0
0 Root Bridge
If I go through
Core it costs
27.
If I go
through D2
it costs 38.
If I go
through A1 it
costs 23.
If I go through
A2 it costs 19.
This is the best
path to the
Root!
Rick Graziani graziani@cabrillo.edu 55
Elect Root Ports:
• This is from the switch’s perspective.
• Switch, “What is my cost to the Root Bridge?”
• Later we will look at Designated Ports, which is from the Segment’s perspective.
If I go through
Core it costs
27.
If I go
through D2
it costs 38.
If I go
through A1 it
costs 23.
If I go through
A2 it costs 19.
This is the best
path to the
Root!
Rick Graziani graziani@cabrillo.edu 56
Elect Root Ports
• Every non-Root bridge must select one Root Port.
• A bridge’s Root Port is the port closest to the Root Bridge.
• Bridges use the Root Path Cost to determine closeness.
? ?
23 23
27 27
38 38
19 23
23 19 RP
RP
23 23 0
19 RP 0
0 Root Bridge
? ?
23 23
27 27
38 38
19 23
23 19 RP
RP
23 23 0
19 RP 0
0 Root Bridge
? ?
RP 23 23
My BID is My BID is
32769.0005.5E0D.9315 32769.0060.47B0.5850
Lower BID 27
27
38 38
19 23
23 19 RP
RP
23 23 0
19 RP 0
0 Root Bridge
STP Convergence
Step 1 Elect one Root Bridge
Step 2 Elect Root Ports
Step 3 Elect Designated Ports
• The loop prevention part of STP becomes evident during this step, electing
designated ports.
• A Designated Port functions as the single bridge port that both sends and
receives traffic to and from that segment and the Root Bridge.
• Each segment in a bridged network has one Designated Port, chosen
based on cumulative Root Path Cost to the Root Bridge.
• The switch containing the Designated Port is referred to as the Designated
Bridge for that segment.
• To locate Designated Ports, lets take a look at each segment.
• Segment’s perspective: From a device on this segment, “Which switch
should I go through to reach the Root Bridge?”
– Root Path Cost, the cumulative cost of all links to the Root Bridge.
– Obviously, the segment has not ability to make this decision, so the
perspective and the decision is that of the switches on that segment.
Rick Graziani graziani@cabrillo.edu 60
• A Designated Port is elected for every segment.
• The Designated Port is the only port that sends and receives traffic to/from that segment to
the Root Bridge, the best port towards the root bridge.
• Note: The Root Path Cost shows the Sent Root Path Cost.
• This is the advertised cost in the BPDU, by this switch out that interface, i.e. this is the cost of
reaching the Root Bridge through me!
RP 23 23
19 19
19 19
19 19
19 19 RP
RP
19 19 0
19 RP 0
0 Root Bridge
RP 23 23
? ?
19 19
?
19 19
19 19
19 RP ? ? 19 RP
? ?
19 19 0
19 RP ? 0
Root Bridge
0
RP 23 23
19 19
My19 designated
What is my
port
best
willpath
be 19
0
via Access
to the2Root
(Fa0/5).
Bridge,
It’s 19
the
19
19
best path,
via Access
lowest Root
1 or 0Path,
via
19 19 RP
RP to the Root
Access
Bridge.
2?
19 19 0
19 RP ? DP 0
Root Bridge
0
RP 23 23
19 19
19 19
19 19
19 RP
? 19 RP
?
19 19 DP 0 DP
19 RP DP 0
0 Root Bridge
RP 23 23
32769.0005.5E0D.9315
19 19
32769.0003.E461.46EC 19 RP DP 0
0 Root Bridge
Lower BID
Rick Graziani graziani@cabrillo.edu 65
Access 1 has Lower Sender BID
Distribution1# show spanning-tree detail
Port 26 (GigabitEthernet0/2) of VLAN0030 is designated blocking
Port path cost 4, Port priority 128, Port Identifier 128.26
Designated root has priority 128, address 000C.CF0B.1503
Designated bridge has priority 32769, address 0003.E461.46EC
Designated port id is 128.26, designated path cost 4
Timers: message age 16, forward delay 0, hold 0
Number of transitions to forwarding state: 1
Link type is point-to-point by default
RP 23 23
32769.0005.5E0D.9315 32769.0060.47B0.5850
19
Lower BID
DP
19
?
19 19
19 19
19 RP 19 RP
DP
19 19 DP 0 DP
19 RP DP 0
0 Root Bridge
RP 23 23
32769.0060.47B0.5850
19 19
DP
19 19
19
19
19
RP ? 19 RP
32769.0003.E461.46EC DP
19 DP 19 DP 0 DP
Lower BID 19 RP DP 0
0 Root Bridge
19 19
DP
19 19
19 19
19 RP 19 RP
DP
19 19 DP 0 DP
DP
19 RP DP 0
0 Root Bridge
RP 23 23
X
NDP
DP
19 19 DP
DP
19
NDP
19 X
NDP
X 19
RP
19
X
NDP 19 RP
19
DP
19 19 DP 0 DP
DP
19 RP DP 0
0 Root Bridge
0/1
• If the path cost and bridge IDs are equal (as in the case of parallel links),
the switch goes to the port priority as a tiebreaker.
• This is the sender’s Port priority + Port ID
• Lowest port priority wins (all ports set to 128).
• .
• If all ports have the same priority, the port with the lowest port number
forwards frames.
Rick Graziani graziani@cabrillo.edu 75
Port Cost/Port ID Five-Step decision Sequence
• Fa 0/3 received a lower Port ID value than Fa 04. Step 1 - Lowest BID
• More later (Fast EtherChannel) Step 2 - Lowest Path Cost to Root Bridge
Step 3 - Lowest Sender BID
Step 4 - Lowest Port Priority
Step 5 - Lowest Port ID
RP
19
NDP
19
DP
DP
Root VLAN 20
Example:
• A network that contains 15 switches and 146
segments (every switchport is a unique segment)
would result in:
– 1 Root Bridge
– 14 Root Ports
– 146 Designated Ports
Building active topology. Thinks port can be selected root or designated port.
Returns to blocking (NDP) if cannot become root or designated port.
Learning Receive and send Updating Table None sent/received Forward delay 15 sec
Building bridging table. Switch can now learn source MAC Addresses but is not
formally receiving frames in order to forward them.
Forwarding Receive and send Updating Table Sent and received Continuous if up and no
loop detected
Rick Graziani graziani@cabrillo.edu 85
Ports and States
• Ports
• Blocked - Doesn't send BPDU's, but is receiving them.
• Designated - Send BPDU's and Receives BPDU's.
• Root - Doesn't send BPDU's, but is receiving them.
• Port states:
• Blocking: State where the switch port can receive BPDU, but can not
forwarding user traffic or BPDUs.
• Listening: State where the switch port can send & receive BPDU, but
can not forwarding user traffic.
• Learning: State where the switch port can learn MAC address, send
and receive BPDU, but not forwarding user traffic.
• Forwarding: State where the switch port can learn MAC address, send
and receive BPDU, and forwarding user traffic.
2
L is te n in g
5
3
4
1
D is a b le d o r 4
B lo c k in g L e a r n in g
Down
2
4
5
6
2
F o r w a r d in g
S ta n d a rd S ta te s C is c o S p e c ific S ta te s
( 1 ) P o r t e n a b le d o r in it ia liz e d (6 ) P o rtF a s t
( 2 ) P o r t d is a b le d o r f a ile d ( 7 ) U p lin k F a s t
( 3 ) P o r t s e le c t e d a s R o o t o r D e s ig n a t e d P o r t
( 4 ) P o r t c e a s e s to b e a R o o t o r D e s ig n a te d P o r t
( 5 ) F o r w a r d in g tim e r e x p ir e s
Hello Time
• IEEE specifies default of 2 seconds.
• The interval between Configuration BPDUs.
• The Hello Time value configured at the root bridge determines
the Hello Time for all nonroot switches.
• Locally configured Hello Time is used for the TCN BPDU.
Modifying Timers
• Do not change the default timer values without careful consideration.
• Cisco recommends to modify the STP timers only on the root bridge
• The BPDUs pass these values from the root bridge to all other bridges in the
network.
• It can take 30-50 seconds for a switch to adjust to a change in topology.
Current Root
Bridge
• Modify the topology so that the Core switch is the root bridge and
Distribution1 is the secondary root bridge for VLAN 1.
Before After
Root
• STP
– PortFast
– BPDU Guard
– Root Guard
– UplinkFast
– BackboneFast
• Per VLAN Spanning Tree (PVST+)
• Rapid Spanning Tree Protocol (RSTP)
• Multiple Spanning Tree Protocol (MST)
– MST is also known as Multiple Instance Spanning Tree
Protocol (MISTP) on Cisco Catalyst 6500 switches and
above
Rick Graziani graziani@cabrillo.edu 107
Helping STP protect your LAN
from Problems
PortFast
BPDU Guard
Root Guard
UplinkFast
BackboneFast
PortFast
Forwarding
Learning
Listening
BlockingState
State
State I’m adding
Powered any
On addresses on
this port to
my MAC
Address
• Host powered on. Table.
• Port moves from blocking state immediately to listening state (15
seconds).
– Determines where switch fits into spanning tree topology.
• After 15 seconds port moves to learning state (15 seconds).
– Switch learns MAC addresses on this port.
• After 15 seconds port moves to forwarding state (30 seconds total).
Forwarding
Learning
Listening
BlockingState
State
State
Powered
On
DHCP Discovery
Timeout
IP Address = 169.x.x.x
Forwarding
Portfast enabled
State
Powered
On
DHCP Discovery
DHCP Offer
• The purpose of PortFast is to minimize the time that access ports wait for
STP to converge.
• When a port comes up, the port immediately moves into Forwarding state.
• The advantage of enabling PortFast is to prevent DHCP timeouts.
• Host sends DHCP Discovery
• Host can now can IP addressing information.
• BPDU Guard
• BPDU Filter
• Root Guard
• Loop Guard
• Coast Guard
STP Reconvergence?
• Even though PortFast is enabled, the interface will listen for BPDUs.
• A port configured with PortFast will go into blocking state if it receives a Bridge
Protocol Data Unit (BPDU).
• This could lead to false STP information that enters the switched network and
causes unexpected STP behavior.
• Newly connected switch could advertise itself as the root.
• BPDU Guard: Developed to protect integrity of switch ports with PortFast enabled
but also keeps maintains STP integrity by disallowing unauthorized switches.
Rick Graziani graziani@cabrillo.edu 118
Solution: BPDU Guard
Err-Disable,
Shutdown
BPDU
| No BPDUs sent
Portfast &
BPDU Guard
• When the BPDU guard feature is enabled on the switch, STP shuts down PortFast
enabled interfaces that receive BPDUs instead of putting them into a blocking state.
– Errdisable: Port must be manually re-enabled or automatically recovered via timers.
• BPDU guard will also keep switches added outside the wiring closet by users from
impacting and possibly violating Spanning Tree Protocol.
Rick Graziani graziani@cabrillo.edu 119
Portfast + BPDU Guard
Protect Protect
Potential Root
Potential Root
• UplinkFast must
be disabled
because it
cannot be used
with root guard.
Distribution1(config)#interface fa 0/3
Distribution1(config-if-range)#spanning-tree guard root
Distribution1(config)#interface gig 0/2
Distribution1(config-if-range)#spanning-tree guard root
Distribution2(config)#interface fa 0/3
Distribution2(config-if-range)#spanning-tree guard root
Distribution2(config)#interface gig 0/1
Distribution2(config-if-range)#spanning-tree guard root
Root
Guard I no longer
want to be
root. I have
I wantbeento
I STP
will now
Inconsistent
transition to
Superior be root
reconfigured
BPDU to be a non-
listening
State – no
sate,
traffic
thenis learning bridge!
state,
passed.
then forwarding sate. root bridge.
X
forwarding
• UplinkFast must have direct knowledge of the link failure in order to move a
blocked port into a forwarding state.
• Single Root Port but multiple potential root ports.
• If Root Port fails, next-lowest path cost is unblocked and used without delay
(almost).
– This switchover occurs within 1 second.
Rick Graziani graziani@cabrillo.edu 126
UplinkFast
Access1(config)#spanning-tree uplinkfast
Switch(config)#spanning-tree backbonefast
• Backbone fast is a Cisco proprietary feature that, once enabled on all switches can
save a switch up to 20 seconds (Max Age) when it recovers from an indirect link
failure.
• Configured in global configuration mode and should be enabled on all switches in
the network.
– Requires the use of RLQ (Root Link Query) requests and replies.
– Disabled by default.
Rick Graziani graziani@cabrillo.edu 128
I just
Thisheard from
new BPDU
My link to the Root Core that they
is inferior to the
Root has are still
onethe Root.
it had
gone
Thanks down.
for I I will:
stored for this
X
Forwarding
Blocking
Listening
telling
have nome RP • Send
portBPDU to
so I will
alternate
Core is thepath RP D1 ignore it.
toRoot.
it. So,
I will
I’m After 20 seconds
• Transition port
Inferior BPDU Let me send
the
change
new root
my this port
immediately will now
to
my current
RP
andtosendFa 0/5.
out go into
listening
Root state
a query
my BPDUs Forwarding20 state.
saving (RLQ).
on all ports. seconds (Max
Age)
= Core
= Dist1
Designated Port
BPDU
Blocked Port
BPDU Received only,
none sent
BPDU BPDU
BPDU
BPDU No BPDU’s Received
Change to Forwarding State
• STP uses Bridge Protocol Data Units (BPDUs).
• If a switch’s port in blocking port stops receiving BPDUs:
– STP eventually ages out the STP information for the port (up to 50 secs)
– Moves port to forwarding state.
• This creates a forwarding loop or STP loop.
• How is it possible for the switch to stop receiving BPDUs while the port is up?
– The reason is unidirectional link.
Rick Graziani graziani@cabrillo.edu 132
Unidirectional Link
BPDU
No BPDU’s Received
Change to Forwarding State
• RFC 5171: “Issues arise when, due to mis-wirings or to hardware faults, the
communication path behaves abnormally and generates forwarding anomalies.
• Link fails in the direction of SwitchC.
– SwitchC stops receiving traffic from SwitchB.
– However, SwitchB still receives traffic from C.
• UDLD is a Layer 2 (L2) protocol that works with the Layer 1 (L1) mechanisms
to determine the physical status of a link.
Rick Graziani graziani@cabrillo.edu 134
ULDP
My device/port
ID & your
device port ID Layer 1: Auto-
negotiation
My device/port configured
ID & your (speed/duplex)
device port ID
Layer 2: UDLD
configured
My device/port
ID & your
X
device port ID Unidirectional link failure
My device/port
ID & your UDLD-3-DISABLE: Unidirectional
device port ID link detected on port 1/2. Port
disabled
Port disabled
Loop! X BPDU
No BPDU’s Received
No Loopguard Configured
Change to Forwarding State
BPDU
%SPANTREE-2-LOOPGUARD_BLOCK:
Loop guard blocking port
FastEthernet1/0 on VLAN0010
Loopguard Configured
Inconsistent Blocking State
• Fast Ethernet 0/1 (active link) forwarding traffic between port Ethernet 0/1
and Switch B
• Fast Ethernet 0/2 (the backup link) and Switch C is not forwarding traffic.
• If port Fast Ethernet 0/1 goes down, port Fast Ethernet 0/2 comes up and
starts forwarding traffic to Switch C.
• When port Fast Ethernet 0/1 comes back up, it goes into standby mode and
does not forward traffic; port Fast Ethernet 0/2 continues to forward traffic.
Rick Graziani graziani@cabrillo.edu 142
Flex Links
• If Fast Ethernet 0/1 shuts down, Fast
Ethernet 0/2 starts forwarding traffic.
• If there is no traffic from the PC to the server
after failover to Fast Ethernet 0/2…
• ….Switch C does not learn the MAC address
of the PC on Fast Ethernet 0/4,
• ….Switch C keeps forwarding traffic from the
server to the PC out of Fast Ethernet 0/3.
• Traffic loss from the server to the PC. Dummy
Multicast
• To alleviate this problem, the feature sends
out a dummy multicast packet with the X
Active Backup
source MAC address of the PC over Fast
Ethernet 0/2.
• Switch C learns the PC MAC address on
Fast Ethernet 0/4 and starts forwarding traffic
from the server to the PC out of Fast
Ethernet 0/4.
• One dummy multicast packet is sent out for
every MAC address.
Rick Graziani graziani@cabrillo.edu 143
STP Recommendations
802.1D 802.1w
vs
• RSTP defines port states based on what it does with incoming data frames.
• Discarding
– Incoming frames are dropped
– No MAC Addresses learned
– Combination of 802.1D (Disabled), Blocking and Listening
• Learning
– Incoming frames are dropped
– MAC Addresses learned
• Forwarding
– Incoming frames are forward.
• Edge port will never have a switch connected to it so cannot form bridging
loops.
• Immediately transitions to forwarding state.
• Traditional identified with STP PortFast feature.
• For familiarity the command is the same: spanning-tree portfast
• Never generates topology changes notifications (TCNs) when the port transitions
to a disabled or enabled status.
• If an edge port receives a BPDU, it loses its Edge Port status becomes a normal
spanning-tree port.
Rick Graziani graziani@cabrillo.edu 157
Non-Edge Ports
• Root Port
– The one switch port on each switch that has the best root path cost to the root.
• Point-to-Point Port (Link Type)
– Port operating in full-duplex mode.
– Connects to another switch and becomes a Designated Port.
– Uses a quick handshake with neighboring switch rather than timers to decide
port state.
• Shared Medium Port (Link Type)
– Port operating in half-duplex mode.
– It is assumed that the port is connected to shared media where multiple
switches might exist.
Rick Graziani graziani@cabrillo.edu 158
Point-to-Point: The Quick Handshake
Proposal
Root RP
A DP B
Agreement
Proposal
Root DP DP
DP RP
A B C
Agreement
Proposal
Root DP RP DP RP C DP RP D
A B
Agreement
802.1D 802.1D
• 802.1D
– Switch detects a state change (up or down), it sends the Root Bridge a TCN BPDU.
– The Root Bridge sends out a Configuration BPDU (TCN bit set) to all switches to
tell them about the change. (30 seconds before Forwarding)
• RSTP
– Detects a topology change only when a nonedge port transitions to the
Forwarding State.
– RSTP uses its convergence mechanisms (Edge Ports, Point-to-Point ports,
handshaking, etc.) to prevent bridging loops.
– Therefore, topology changes are detected only so MAC address tables can be
updated and corrected.
– This means that a loss of connectivity is not considered as a topology change any
more, contrary to 802.1D (that is, a port that moves to blocking no longer generates
a TC).
Rick Graziani graziani@cabrillo.edu 161
RSTP Topology Change
Notifications
RSTP
• When a topology change occurs:
– Switch flushes the MAC addresses associated
with all nonedge ports. RSTP no longer uses the specific
TCN BPDU, unless a legacy bridge
– Switch sends BPDU with TCN bit set to all
needs to be notified
neighbors so they can update their MAC Address
tables too.
• When a bridge receives a BPDU with the TCN bit set from a neighbor:
– It clears the MAC addresses learned on all its ports, except the one the port that
it receives the topology change.
– It sends BPDUs with TCN set on all its designated ports and root port (RSTP no
longer uses the specific TCN BPDU, unless a legacy bridge needs to be notified).
• This way, the TCN floods very quickly across the whole network - now a one step
process.
• The initiator of the topology change floods this information throughout the network,
as opposed to 802.1D where only the root did.
• Much faster than the 802.1D equivalent < wait for the root bridge to be notified, and
then max age plus forward delays>.
• In just a few seconds, or a small multiple of hello-times, most of the entries in the
CAM tables of the entire network (VLAN) flush.
• This approach results in potentially more temporary flooding, but on the other hand it
clears potential stale information and allows rapid convergence.
Rick Graziani graziani@cabrillo.edu 162
Rapid PVST Implementation Commands
• 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 to match the physical topology
of the network
– Thus reduce the CPU cycles of a switch.
• Allows the network administrator to configure the exact number of instances.
• PVST+ runs a single instance of STP for each VLAN and does not take into
consideration the physical topology.
– May have 1,000 VLANs but only 2 different topologies (2 different Root Bridges).
– PVST+ will still create 1,000 instances of STP
• MST, on the other hand, uses a minimum number of STP instances to match the
number of physical topologies present.
– May have 1,000 VLANs but only 2 different topologies (2 different Root Bridges).
– MST will let you specify only 2 instances of STP.
Rick Graziani graziani@cabrillo.edu 168
MST Regions
• MST combines some but not necessarily all VLANs into logical spanning-tree
instances.
• This difference raises the problem of determining which VLAN is supposed to
be associated with which instance.
• VLAN-to-instance association is communicated by tagging the BPDUs so that
the receiving device can identify the instances and the VLANs to which they
apply.
MST
Region
• MST Region is a group of switches placed under a common administration (like an AS).
• In most networks a single MST region is sufficient.
– A single MST Region can handle 15 STP instances (topologies).
• Within a region, all switches must run the instance of MST as defined by:
– MST configuration name (32 characters)
– MST configuration revision number ( 0 to 65,535)
– MST instance-to-VLAN mapping table (4,096 entries)
• MST was designed to work with all forms of STP.
• IST (Internal Spanning Tree) instance runs to work out a loop-free topology inside the
MST Region.
• IST presents the entire MST region as a single virtual switch (bridge) to the CST (802.1D)
outside.
Rick Graziani graziani@cabrillo.edu 170
MST
• Configure SW1 as primary root bridge for MST instance 1 and secondary root
for instance 2
• Configure SW2 as secondary root bridge for MST instance 1 and primary root
for instance 2.
• Change STP mode to MST on all three switches
Rick Graziani graziani@cabrillo.edu 183
SW3# show spanning-tree summary
Switch is in mst mode (IEEE Standard)
<... output omitted ...>
• MST runs three instances: the default MSTI0 and the two you configured
(MSTI1 and MSTI2).
Rick Graziani graziani@cabrillo.edu 184
SW3(config)# spanning-tree mst configuration
SW3(config-mst)# show current
Current MST configuration
Name [CCNP]
Revision 1 Instances configured 3