RSTP (rapid spanning tree protocol)

Netwaxlab 3,154 views 9 slides Apr 29, 2015
Slide 1
Slide 1 of 9
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9

About This Presentation

In 2001, the IEEE introduced Rapid Spanning Tree Protocol (RSTP) as 802.1w. RSTP provides significantly
faster spanning tree convergence after a topology change, introducing new convergence behavior and
bridge port roles to do this. RSTP was designed to be backwards-compatible with standard STP.
Whi...


Slide Content

RSTP (Rapid Spanning Tree Protocol)

In 2001, the IEEE introduced Rapid Spanning Tree Protocol (RSTP) as 802.1w. RSTP provides significantly
faster spanning tree convergence after a topology change, introducing new convergence behavior and
bridge port roles to do this. RSTP was designed to be backwards-compatible with standard STP.
While STP can take 30 to 50 seconds to respond to a topology change, RSTP is typically able to respond
to changes within 3 × Hello times (default: 3 times 2 seconds) or within a few milliseconds of a physical
link failure. The so-called Hello time is an important and configurable time interval that is used by RSTP
for several purposes; its default value is 2 seconds.
Standard IEEE 802.1D-2004 incorporates RSTP and obsoletes the original STP standard.
Rapid Spanning Tree Operation
RSTP adds new bridge port roles in order to speed convergence following a link failure. The number of
states a port can be in has been reduced to three instead of STP's original five.
RSTP Bridge Port Roles
1. Root Port- The port that receives the best BPDU on a bridge is the root port. This is the port that
is the closest to the root bridge in terms of path cost. The STA elects a single root bridge in the
whole bridged network (per-VLAN). The root bridge sends BPDUs that are more useful than the
ones any other bridge sends. The root bridge is the only bridge in the network that does not have
a root port. All other bridges receive BPDUs on at least one port.


2. Designated Port- A port is designated if it can send the best BPDU on the segment to which it is
connected. 802.1D bridges link together different segments, such as Ethernet segments, to
create a bridged domain. On a given segment, there can only be one path toward the root
bridge. If there are two, there is a bridging loop in the network. All bridges connected to a given
segment listen to the BPDUs of each and agree on the bridge that sends the best BPDU as the
designated bridge for the segment. The port on that bridge that corresponds is the designated
port for that segment.


Figure 1 Root Port

RSTP (Rapid Spanning Tree Protocol)






3. Alternate and Backup Port Roles- These two port roles correspond to the blocking state of
802.1D. A blocked port is defined as not being the designated or root port. A blocked port
receives a more useful BPDU than the one it sends out on its segment. Remember that a port
absolutely needs to receive BPDUs in order to stay blocked. RSTP introduces these two roles for
this purpose.
An alternate port receives more useful BPDUs from another bridge and is a port blocked. This is
shown in this diagram:






A backup port receives more useful BPDUs from the same bridge it is on and is a port blocked.
This is shown in this diagram:





This distinction is already made internally within 802.1D. This is essentially how Cisco UplinkFast
functions. The rationale is that an alternate port provides an alternate path to the root bridge
and therefore can replace the root port if it fails. Of course, a backup port provides redundant
Figure 2 Designated Port
Figure 3 Alternate Port
Figure 4 Backup Port

RSTP (Rapid Spanning Tree Protocol)

connectivity to the same segment and cannot guarantee an alternate connectivity to the root
bridge. Therefore, it is excluded from the uplink group.
New Port States
The 802.1D is defined in these five different port states:
1. Disabled
2. Listening
3. Learning
4. Blocking
5. Forwarding
STP (802.1D) Port State
RSTP (802.1w)
Port State
Is Port Included in Active
Topology?
Is Port Learning MAC Addresses?
Disabled Discarding No No
Blocking Discarding No No
Listening Discarding Yes No
Learning Learning Yes Yes
Forwarding Forwarding Yes Yes

RSTP Switch Port States
1. Discarding- No user data is sent over the port.

2. Learning- The port is not forwarding frames yet, but is populating its MAC-address-table.

3. Forwarding- The port is fully operational.

4. Detection of root switch failure is done in 3 hello times, which is 6 seconds if the default hello
times have not been changed.

5. Ports may be configured as edge ports if they are attached to a LAN that has no other bridges
attached. These edge ports transition directly to the forwarding state. RSTP still continues to
monitor the port for BPDUs in case a bridge is connected. RSTP can also be configured to

RSTP (Rapid Spanning Tree Protocol)

automatically detect edge ports. As soon as the bridge detects a BPDU coming to an edge port,
the port becomes a non-edge port.

6. RSTP calls the connection between two or more switches as a "link-type" connection. A port that
operates in full-duplex mode is assumed to be point-to-point link, whereas a half-duplex port
(through a hub) is considered a shared port by default. This automatic link type setting can be
overridden by explicit configuration. RSTP improves convergence on point-to-point links by
reducing the Max-Age time to 3 times Hello interval, removing the STP listening state, and
exchanging a handshake between two switches to quickly transition the port to forwarding state.
RSTP does not do anything differently from STP on shared links.

7. Unlike in STP, RSTP will respond to BPDUs sent from the direction of the root bridge. An RSTP
bridge will "propose" its spanning tree information to its designated ports. If another RSTP
bridge receives this information and determines this is the superior root information, it sets all
its other ports to discarding. The bridge may send an "agreement" to the first bridge confirming
its superior spanning tree information. The first bridge, upon receiving this agreement, knows it
can rapidly transition that port to the forwarding state bypassing the traditional
listening/learning state transition. This essentially creates a cascading effect away from the root
bridge where each designated bridge proposes to its neighbors to determine if it can make a
rapid transition. This is one of the major elements that allows RSTP to achieve faster
convergence times than STP.

8. As discussed in the port role details above, RSTP maintains backup details regarding the
discarding status of ports. This avoids timeouts if the current forwarding ports were to fail or
BPDUs were not received on the root port in a certain interval.

9. RSTP will revert to legacy STP on an interface if a legacy version of an STP BPDU is detected on
that port.
New BPDU Format
Few changes have been introduced by RSTP to the BPDU format. Only two flags, Topology Change (TC)
and TC Acknowledgment (TCA), are defined in 802.1D. However, RSTP now uses all six bits of the flag
byte that remain in order to perform:
 Encode the role and state of the port that originates the BPDU
 Handle the proposal/agreement mechanism
(Note: Bit 0 (Topology Change) is the least significant bit.)

RSTP (Rapid Spanning Tree Protocol)








Another important change is that the RSTP BPDU is now of type 2, version 2. The implication is that
legacy bridges must drop this new BPDU. This property makes it easy for a 802.1w bridge to detect
legacy bridges connected to it.
New BPDU Handling
1. BPDU are Sent Every Hello-Time.
2. Faster Aging of Information.
3. Accepts Inferior BPDUs.
RSTP Convergence Process
Its convergence Process is divided into 3 steps
1. Proposal– In this step they will exchange their BPDU.
Type 2, Version 2
2. Synchronization– In this step a switch will put its all trunk ports in discarding state. To avoid
possible loops.

3. Agreement– A switch will elect for RP and block port. After election, switch will send a request to
neighbor switch that you should be DP.
In this a switch will decide its own root port and will send a message to its neighbor switch that you
should be a designated port.



Figure 5 New BPDU Format

RSTP (Rapid Spanning Tree Protocol)












RSTP Port Types
 Edge Port Switch to PC/Router/Server
 Point-Point Switch to Switch
 Shared port Switch to Hub (Ethernet Device)
(Note: RSTP (1:1) Single instance for single Vlan.)
Mixed STP and RSTP Networks
RSTP IEEE 802.1w is fully compliant with STP IEEE 802.1d. Your network can consist of bridges running
both protocols. STP and RSTP in the same network can operate together to create a single spanning tree
domain.
The switch monitors the traffic on each port for BPDU packets. When you set the switch to RSTP mode,
all the ports operate in that mode and reject STP BPDU packets. When you set the switch to operate in
STP-compatible mode, the ports can receive either RSTP or STP BPDU packets.
Rapid Spanning Tree Configuration Menu
 Root Port
The active port on the switch that is communicating with the root bridge. If the switch is the root
bridge for the LAN, then there is no root port and the root port parameter will be 0.
Figure 6

RSTP (Rapid Spanning Tree Protocol)

 Root Path Cost
The sum of all the root port costs of all the bridges between the switch’s root port and the root
bridge including the switch’s root port cost.
 Time Since Topology Change
The time in seconds since the last topology change took place. When RSTP detects a change to
the LAN’s topology or when the switch is rebooted, this parameter is reset to 0 seconds and
begins incrementing until the next topology change is detected.
 Topology Change Count
An integer that reflects the number of times RSTP has detected a topology change on the LAN
since the switch was initially powered on or rebooted.
The following parameters refer to the designated root bridge:
 Designated Root
This parameter includes two fields: the root bridge priority and the MAC address of the root
bridge. For example, 1000 00C08F1211BB shows the root bridge priority as 1000, and
00C08F1211BB as the MAC address.
 Hello Time
The hello time. See Hello Time and Bridge Protocol Data Units (BPDUs). This parameter affects
only the root bridge.
 Maximum Age
The maximum amount of time that BPDUs are stored before being deleted on the root bridge.
 Forward Delay
The time interval between generating and sending configuration messages by the root bridge.
The following parameters refer to the switch.
 Bridge ID
The MAC address of the bridge. The bridge identifier is use as a tie breaker in the selection of the
root bridge when two or more bridges have the same bridge priority. You cannot change this
setting.

RSTP (Rapid Spanning Tree Protocol)

 Bridge Hello Time
This is the time interval between generating and sending configuration messages by the bridge.
This parameter is active only when the switch is the root bridge.
 Bridge Maximum Age
The length of time after which stored bridge protocol data units (BPDUs) are deleted by the
bridge.
 Bridge Forward Delay
This is the time interval between generating and sending configuration messages by the bridge.
Topology Information Menu
 Trunk- The trunk of which the port is a member.

 Link- Whether the link on the port is up or down.

 Desig. Root- The designated root bridge to which the switch’s root port is actively connected.

 Desig. Cost- The sum of all the root port costs on all bridges, including the switch, between the
switch and the root bridge.

 Desig. Bridge- An adjacent bridge to which the root port of the switch is actively connected.

 Desig. Port- The root bridge to which the root port of the switch is actively connected.
RSTP Quick Summary
RSTP provides faster convergence than 802.1D STP when topology changes occur.
 RSTP defines three port states: discarding, learning, and forwarding.
 RSTP defines five port roles: root, designated, alternate, backup, and disabled.

RSTP (Rapid Spanning Tree Protocol)

Configuration Instruction

 Step1: Configure SW1, SW2 and SW3 to run Rapid Per-VLAN Spanning Tree Protocol.
SW1(config)#spanning-tree mode rapid-pvst
SW1#show spanning-tree bridge
SW2(config)#spanning-tree mode rapid-pvst
SW2#show spanning-tree bridge
SW3(config)#spanning-tree mode rapid-pvst
SW3#show spanning-tree bridge
 Step 2: Configure SW1 as the ROOT bridge for VLAN 1 and 10. Verify your configuration on SW2.
SW1(config)#spanning-tree vlan 1 root primary
SW1(config)#spanning-tree vlan 10 root primary
SW2#show spanning-tree vlan 1
SW2#show spanning-tree vlan 10
 Step 3: Configure SW2 as the ROOT bridge for VLAN 20. Verify your configuration on SW1.
SW2(config)#spanning-tree vlan 20 root primary
SW1#show spanning-tree vlan 20
 Step 4: Configure SW3 as the ROOT bridge for VLAN 30. Verify your configuration on SW1.
SW3(config)#spanning-tree vlan 30 root primary
SW1#show spanning-tree vlan 30
Figure 7