Rapid STP

Because of convergence issues in the 802.1D STP algorithm, IEEE developed 802.1W. 802.1W, also called Rapid STP or RSTP, includes enhancements to speed up the convergence with STP. One of the main problems of using Cisco's STP enhancements PortFast, UplinkFast, and BackboneFast is that they're proprietary and function only on Cisco switches. In most instances, you can use RSTP instead of Cisco's proprietary STP enhancements and get the same or better performance from your STP process.

For trunk connections using ISL or 802.1Q between Cisco switches, Cisco has enhanced PVST+ to allow RSTP to function correctly. Cisco calls this enhancement RPVST+. You do not need to configure anything special on the switch to use RPVST+.

BPDUs

Just as with STP, RSTP uses BPDUs to elect a root switch, discover the topology of the network, share STP configuration information, notify other switches of topology changes, and verify the continuing existence of other switches. RSTP uses the same BPDU format as STP. If you recall from Chapter 4, "Spanning Tree Protocol," a BPDU frame contains a type field. With 802.1D, the type field was used to encode two different STP messages: a topology change notification and a topology change acknowledgment. Two bits were used to encode these message types.

RSTP, on the other hand, uses all six of the remaining bits, but not the 2 bits that STP uses. IEEE decided on this approach so that in a mixed environment where some switches support RSTP and some support only STP, both types of switches would understand the BPDU framing format. Also, RSTP switches would be able to easily detect BPDUs from STP switches by looking at the 2-bit values in the type field RSTP uses only the other 6 bits. Therefore, there are two different versions of BPDUs: switches running STP (802.1D) use version 1, and switches running RSTP (802.1W) use version 2.

It's important to point out that RSTP switches can understand STP BPDUs and can incorporate STP switches into the current Layer 2 loop-free network. However, in a mixed network of RSTP and STP switches, the RSTP switches lose all the fast convergence features that will be discussed later in this section. In other words, in a mixed network, an RSTP switch essentially functions as an STP switch.

Besides the use of the type field in a BPDU frame, there is another difference between RSTP and STP. With STP, the root generates BPDUs every 2 seconds and other bridges relay these hellos. A nonroot switch generates a BPDU only when it receives a BPDU on its root port. With STP, switches detect failures by missed BPDUs from the root on forwarding ports.

RSTP has every switch generate BPDUs every 2 seconds. These BPDUs contain the switch's RSTP configuration information. If one switch misses three consecutive hello BPDUs from a neighboring switch, it considers the connection between itself and the neighbor to have failed, allowing the detection of failures to occur more quickly (6 seconds or less) than with 802.1D (20 seconds with the maximum age timer).

Port States

RSTP is based on 802.1D STP. RSTP chooses one switch to function as the root and all switches then designate the appropriate port states for their ports to ensure a loop-free topology. Many of the terms and concepts are the same between the two STPs such as port and path cost, port priority, switch or bridge ID, and so on. However, compared to STP, RSTP contains two additional port roles Alternate and Backup which help with fast convergence. Table 5.1 lists RSTP's port states and their functions. As you can see from the table, RSTP has only three port states, as compared to STP's five. STP's disabled, blocking, and listening states have been combined into a single RSTP state: discarding.

Table 5.1. RSTP Port States

RSTP Port State

Port Included in STP Topology?

Learning MAC Addresses?

Discarding

No

No

Learning

Yes

Yes

Forwarding

Yes

Yes

One problem with STP is that the state the port is placed in is directly associated with the role that the port plays. For example, a root or designated port is in a forwarding state. With RSTP, the role and state that a port is placed in are separate.

graphics/alert_icon.gif

Know the three RSTP port states in Table 5.1: discarding, learning, and forwarding.


Port Roles

RSTP adds two additional port roles to help with convergence issues. Table 5.2 lists all the port roles used in RSTP. As you can see from this table, there are two new port roles: alternate and backup. An alternate port backs up a root port, whereas a backup port backs up a designated port.

Table 5.2. RSTP Port Roles

RSTP Port Role

Explanation

Root

The port used on a switch to reach the root switch.

Designated

The port used on a switch by a segment to reach the root switch.

Alternate

This port serves as a secondary root port in case the primary root port fails. It is in a discarding state unless a failure of the root port or connection occurs, in which case it is moved to a forwarding state.

Backup

This port serves as a secondary designated port in case the primary designated port fails. It is in a discarding state unless a failure of the designated port occurs, in which case it is moved to a forwarding state.

Disabled

This port is not participating in STP and has been disabled.

graphics/alert_icon.gif

Understand the RSTP port roles in Table 5.2: an alternate root port backs up the root port and a backup port backs up the designated port.


One of the interesting things about RSTP is that it uses the same STP algorithm to calculate paths to the root. Therefore, a network using RSTP has the same default loop-free topology that STP would have created. In other words, there are no changes in choosing a root switch, calculating accumulated path costs, or choosing a root or designated port. The main difference is what occurs when changes happen in the network that would normally cause 802.1D STP to rerun, which, as you saw in the previous chapter, creates convergence issues.

Convergence Features

RSTP implements are a handful of features to speed up convergence. The first of those features is similar to Cisco's BackboneFast STP enhancement. With this feature, if an 802.1W switch receives an inferior BPDU (a root BPDU with a better accumulated path cost was received on a nonroot port), the switch floods this new information to other switches and begins its STP calculation process to choose a new root port and form a new loop-free Layer 2 topology.

However, the main convergence enhancement of RSTP is a feature called Rapid Transition to Forwarding (RTF). In 802.1D, switches had to wait for ports to go through all of their states (30 50 seconds) before a port could be placed in a forwarding state and user traffic could be processed. In many examples, this doesn't make sense, especially the Layer 2 disruption of a switched network when only an insignificant topology change occurs such as when a port connected to a PC becomes active.

Edge Port and Link Type

Where 802.1D relied on timers to allow for BPDU information to be propagated to all switches to ensure that a loop-free topology could be created, RSTP uses the two components shown in Table 5.3.

Table 5.3. RSTP Convergence Components

Component

Explanation

Edge port

A port connected to a nonswitch (Layer 2) device, such as a PC, router, or file server.

Link type

The link type of a connection, which is either point-to-point (pt-pt) or a shared medium.

The edge port component is used to determine whether a switch is connected to your switch. It learns this by listening for BPDUs on the port. If your switch doesn't receive any BPDUs on the port, the switch designates the port as an edge port. Changes in the status of an edge port do not cause RSTP to recalculate. In other words, if a PC is connected to your switch, this port is considered an edge port. If you reboot your PC, your switch does not make any changes in RSTP or notify any other devices about this change in port state.

An edge port is left in a forwarding state unless a BPDU is received on it, at which point an RSTP calculation occurs to ensure that no loops have been created. The edge port then loses its status as an edge port and becomes a normal STP port. Cisco's PortFast is similar to RSTP's edge port concept. The major difference is that Cisco's PortFast feature always keeps a port in a forwarding state even if a BPDU is received on it. Therefore, it's possible to have Layer 2 loops with Cisco's PortFast feature if you aren't careful about the ports on which you enable it. RSTP's edge port feature overcomes this problem by listening for BPDUs on the port to ensure that no loops are or will be created. If a port is either an edge port or is in a discarding state, the port is said to be in sync.

The link type of a port is determined by the duplex setting on the port. If your port is configured or detected as full duplex, the link type is considered pt-pt. If your port is configured or detected as half-duplex, the link type is considered as a shared medium.

graphics/alert_icon.gif

Know how RSTP uses edge ports and link types in determining what a port is connected to.


Topology Changes

When any topology change occurs in 802.1D, the root switch is notified first and the root switch then propagates this information to all other switches. When other bridges receive this update, they begin the recalculation process.

With RSTP, only changes on nonedge ports cause a topology change to occur. Therefore, if someone turns on her PC, it does not cause RSTP to perform a recalculation, but it would cause 802.1D to do so. When RSTP detects a topology change, the switch performs the following actions:

  1. The switch starts a timer (called TC While), which is set to two times the hello interval for all nonedge ports, including all designated ports and the root port, if necessary.

  2. The switch removes all MAC addresses from the CAM table associated with only these nonedge ports.

  3. While the timer is active for a port, BPDUs are generated on the port that indicated a topology change (TC).

If a switch receives a BPDU with the TC bit set in the type field, it first clears the CAM table of all MAC addresses associated with the port the BPDU was received on. The switch then repeats the preceding three steps for its remaining nonedge ports.

Using this process, any changes can be immediately propagated throughout the entire Layer 2 network, thus speeding up convergence. Where 802.1D used a two-step process to propagate notification information, RSTP uses only a one-step process; a switch doesn't have to notify the root switch first.

RSTP supports a convergence mechanism that's similar to Cisco's UplinkFast feature. If a root port (or its connection to the next switch) on an RSTP switch fails, RSTP automatically takes the port in an alternate state (the port is still receiving BPDUs from the root) and immediately moves it to a forwarding state.



BCMSN Exam Cram 2 (Exam Cram 642-811)
CCNP BCMSN Exam Cram 2 (Exam Cram 642-811)
ISBN: 0789729911
EAN: 2147483647
Year: 2003
Pages: 171
Authors: Richard Deal

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net