6-46
Catalyst 2900 Series XL and Catalyst 3500 Series XL Software Configuration Guide
78-6511-08
Chapter 6 Configuring the System
Configuring STP
Configuring STP Root Guard
The Layer 2 network of a service provider (SP) can include many connections to switches that are not
owned by the SP. In such a topology, STP can reconfigure itself and select a customer switch as the STP
root switch, as shown in
Figure 6-11
. You can avoid this situation by configuring the root-guard feature
on interfaces that connect to switches outside of your customer’s network. If STP calculations cause an
interface in the customer network to be selected as the root port, root guard then places the interface into
the root-inconsistent (blocked) state to prevent the customer switch from becoming the root switch or
being in the path to the root.
If a switch outside the network becomes the root switch, the interface is blocked (root-inconsistent state),
and STP selects a new root switch. The customer switch does not become the root switch and is not in
the path to the root.
Caution
Misuse of this feature can cause a loss of connectivity.
Figure 6-11 STP in a Service Provider Network
Root guard enabled on a port applies to all the VLANs that the port belongs to. Each VLAN has its own
instance of STP.
Beginning in privileged EXEC mode, follow these steps to set root guard on a port:
Use the no version of the spanning-tree rootguard command to disable the root guard feature.
Customer network
Potential
spanning-tree root without
root guard enabled
Enable the root-guard feature
on these interfaces to prevent
switches in the customer
network from becoming
the root switch or being
in the path to the root.
Desired
root switch
Service-provider network
43578
Command
Purpose
Step 1
configure terminal
Enter global configuration mode.
Step 2
interface interface
Enter interface configuration mode, and enter the port to be configured.
Step 3
spanning-tree rootguard
Enable root guard on the port.
Step 4
end
Return to privileged EXEC mode.
Step 5
show running-config
Verify that the port is configured for root guard.