| 5.4 | STP in the Campus Network | ||
| 5.4.1 | Establishing a root bridge |
A Layer 2 switched environment
requires STP to prevent loops in the network. In this section we
look at modifications that can be made to Spanning Tree in order to
compensate for some of its known issues. Scaling STP involves the
following tasks:
One of the most important decisions that must be made in the Spanning-Tree network is the location(s) of the root bridge(s). Proper placement of the root bridge optimizes the path that is chosen by STP. Proper placement of the root bridge will also provide deterministic paths for data. A bridge can be manually configured to be the root bridge, as well as a backup or secondary root bridge. The job of the secondary root bridge is to take over if the primary root bridge fails. The switch software can be used to configure STP operational parameters in a network. On a set command-based switch, use the set spantree root command to set the primary root for specific VLANs or for all VLANs of the switch. The set spantree secondary command allows you to configure a backup root bridge. To configure the STP root switch on a set-command based switch, enter the following command in privileged mode.
This command is explained in Figure As you can see in Figure The switch software also provides commands that will allow you to view the status of STP. To configure the STP root switch on a Cisco IOS command-based switch, enter the following command in global configuration mode:
As you can see, you must specify the
VLAN instance and specify the priority with a value between 0 and
65535. An example of this command is shown in Figure As you can see by the first show
spanning-tree command in
Figure Use the show spantree command in privileged mode on a set command-based switch to verify the operation and state of each port and VLAN.
|