Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Cisco Press CCNA ICND 2004 - Cisco Press.pdf
Скачиваний:
125
Добавлен:
24.05.2014
Размер:
13.19 Mб
Скачать

46Chapter 2: Spanning Tree Protocol

One of the bridges is elected as root. The election process includes all bridges claiming to be the root, until one bridge is considered best by all. All root bridge interfaces are in forwarding state.

Each bridge receives hello BPDUs from the root, either directly or forwarded by another bridge. Each bridge can receive more than one such message on its interfaces. The port on which the least-cost BPDU is received is called the bridge’s root port. That port is placed in forwarding state.

For each LAN segment, one bridge sends the forwarded BPDU with the lowest cost. That bridge is the designated bridge for that segment. That bridge’s interface on that segment is placed in forwarding state.

All other interfaces are placed in blocking state.

The root sends BPDUs every hello time seconds. The other bridges expect to receive copies of these BPDUs so that they know that nothing has changed. The hello time is defined in the BPDU itself, so all bridges use the same value.

If a bridge does not receive a BPDU for MaxAge seconds, it begins the process of causing the spanning tree to change. The reaction can vary from topology to topology. (MaxAge is defined in the BPDU itself, so all bridges use the same value.)

One or more bridges decide to change interfaces from blocking to forwarding, or vice versa, depending on the change in the network. When moving from blocking to forwarding, the interim listening state is entered first. After the Forward Delay amount of time (another timer defined in the root BPDU), the state is changed to learning. After another Forward Delay amount of time, the interface is placed in forwarding state.

When a switch first transitions to a listening state, the switch sends a TCN BPDU over the new path to the root, forcing switches to quickly remove invalid entries from their MAC address tables.

The Spanning Tree Protocol includes these delays to help ensure that no temporary loops occur.

Optional STP Features

STP has been around for 20 years. It was designed to solve a very specific need, but networking has changed over the years. Likewise, vendors and standards bodies alike have made changes to STP. In fact, Cisco has added several proprietary enhancements to STP and to the logic used by its switches. Also, the IEEE, which owns the STP specifications, has made other enhancements, some similar to Cisco’s proprietary enhancements.

If you plan to work on a production campus LAN network, you should learn more about STP features. Cisco documentation for the 2950 covers many of the details. Go to Cisco.com and search for the document “Catalyst 2950 Desktop Switch Software Configuration Guide, 12.1(11)EA1,” especially for the coverage of STP, RSTP, and optional STP features.

Spanning Tree Protocol 47

EtherChannel

The best way to lower STP’s default 50-second convergence time is to avoid convergence altogether. EtherChannel provides a way to prevent STP convergence from being needed when only a single port or cable failure occurs.

EtherChannel combines from two to eight parallel Ethernet trunks between the same pair of switches, bundled into an EtherChannel. STP treats an EtherChannel as a single link, so if at least one of the links is up, STP convergence does not have to occur. For instance, Figure 2-6 shows the familiar three-switch network, but now with two FastEthernet connections between each pair of switches.

Figure 2-6 Two-Trunk EtherChannels Between Switches

 

Larry

 

 

Archie

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

SW1

SW2

Blocking

SW3

Bob

With each pair of Ethernet links configured as an EtherChannel, STP treats each

EtherChannel as a single link. In other words, both links to the same switch must fail for a switch to need to cause STP convergence. Without EtherChannel, if you have multiple parallel links between two switches, STP blocks all the links except one. With EtherChannel, all the parallel links can be up and working at the same time, while reducing the number of times STP must converge, which in turn makes the network more available.

EtherChannel also provides more network bandwidth. All trunks in an EtherChannel are either forwarding or blocking, because STP treats all the trunks in the same EtherChannel as one trunk. When an EtherChannel is in forwarding state, the switches forward traffic over all the trunks, providing more bandwidth.