BCMSN: Advanced STP Features
Posted by Aragoen Celtdra on June 3rd, 2009
Redundant Link Convergence Features
I. PortFast
- PortFast is an STP feature that allows an access port to immediately transition from blocking to forwarding – bypassing the listening and learning states.
- The purpose of PortFast is to minimize the time that access ports wait for STP to converge.
- The idea is that access port almost always have end-workstation plugged into them, therefore bridging loop is not a concern. And as such, there is no need for the protection of the whole STP cycle (listening and learning states).
- Even with PortFast enabled on a port, Spanning-tree detection is still working. If a loop is detected on that port, the port will move into Blocking state.
- On a PortFast enabled port, TCN BPDUs are not sent if it goes up and down.
Configuring PortFast
- PortFast is disabled by default.
- There are two methods that PortFast can be enabled:
- Globally – use this if configuring on a switch in the Building Access submodule, where all ports connect only to workstations and servers.
- Per interface – use for individual interface.
- Remember to explicitly disable PortFast on uplink ports that connect to distribution layer switches.
Switch(config)#spanning-tree portfast default
Switch(config-if)# [no] spanning-tree portfast
- A special macro command can be used to simultaneously enable PortFast, set the port to access (non-trunking) mode, and disable PAgP (prevent EtherChannel):
Switch(config)# interface type mod/num
Switch(config-if)# switchport host
switchport mode will be set to access
spanning-tree portfast will be enabled
channel group will be disabled
Verifying PortFast Configuration
Switch# show spanning-tree interface fastethernet 0/1 portfast
VLAN0010 enabled
Switch#
II. UplinkFast
- UplinkFast is an STP feature that allows immediate convergence of a backup uplink when a redundant uplink fails.
- Consider an access-layer switch with redundant connection to two distribution-layer switches. When one uplink goes down, the other uplink immediately goes off blocking state and starts forwarding.
- The switchover bypasses the listening and learning states and converges within 5 seconds.
- UplinkFast is enabled for the entire switch and all VLANs.
- It is not allowed on the Root Bridge switch – because the feature works to keep track of possible paths to the root bridge itself.
- UplinkFast makes sure that the switch on with it is turned on does not become the Root Bridge. It also makes sure that the switch doesn’t become a transit switch to get to the Root Bridge.
- The goal is to keep UplinkFast limited to leaf-node switches that are farthest from the Root.
- It raises the bridge priority to 49,152 – making it unlikely to be elected root bridge.
- All the switch ports cost is incremented by 3,000 to make it less likely to be used as paths towards the root for any downstream switches.
Configuring UplinkFast
- As mentioned earlier, UplinkFast affects all VLANs on the switches.
- There is no support for configuring UplinkFast on a per-VLAN basis.
- To configure, enter the following global configuration command:
Switch(config)#spanning-tree uplinkfast [max-update-rate packets-per-second]
- The packets-per-second value is the number of multicast packets transmitted per second
- The default is 150 pps.
Verifying UplinkFast Configuration
Switch# show spanning-tree uplinkfast
UplinkFast is enabled
Station update rate set to 150 packets/sec.
UplinkFast statistics
———————–
Number of transitions via uplinkFast (all VLANs) : 2
Number of proxy multicast addresses transmitted (all VLANs) : 52
Name Interface List
——————– ————————————
VLAN0001 Gi0/1(fwd)
VLAN0010 Gi0/1(fwd)
VLAN0100 Gi0/1(fwd)
III. BackboneFast
- BackboneFast reduces the default convergence time in situations where the root port is lost by an indirect link failure and the backup link leads through a different switch.
- Indirect link failure occurs when a link that is not directly connected to a switch fails. Can you say, duh?
- It does not support failure by a direct link.
- The convergence is reduced from 50 seconds to 30 seconds.
- It doesn’t eliminate the Forward Delay time.
- A switch detects an indirect link failure when it receives inferior BPDUs from its designated bridge on either its root port or a blocked port.
- A switch considers the BPDU an inferior BPDU when a switch receives the BPDU from a designated bridge that identifies the root bridge and the designated bridge as the same switch.
- In other words, the designated bridge thinks of itself as the new root, sending the inferior BPDU, because it lost its connection to the root bridge, sending the inferior BPDU.
- A switch considers the BPDU an inferior BPDU when a switch receives the BPDU from a designated bridge that identifies the root bridge and the designated bridge as the same switch.
- The receiver of the inferior BPDU waits the Max Age time before it will respond to the BPDU.
- While waiting for the Max Age timer to expire, BackboneFast begins to determine whether other alternative paths to the Root Bridge exists according to the following port types that received the inferior BPDU:
- If the inferior BPDU arrives on a port in the Blocking state, the switch considers the Root Port and all other blocked ports to be alternate paths to the Root Bridge.
- If it arrives on the Root Port, all blocked ports are considered to be alternate paths to the Root.
- If arrived on Root Port while no other ports are on blocking state, the switch assumes that it has lost connectivity with the Root Bridge and assumes, then, that it has become the Root Bridge. Backbone Fast allows the switch to do so before the Max Age timer expires.
- If alternate paths are available on switches that receive inferior BPDUs, BackboneFast will send Root Link Queries (RLQ) out these alternate paths to see if upstream switches have connection to the Root Bridge.
- The objective of the RLQ BPDU is to find out whether the current root switch is still up.
- If the Root Bridge or a switch that has lost connection to the Root Bridge receives an RLQ Request, it will respond with an RLQ Reply. If an RLQ Reply is not heard, the RLQ Request propagates towards the Root Bridge until an RLQ Reply can be generated.
- On the local switch, if an RLQ Reply is received on its current Root Port, then the path to the Root Bridge is intact and stable.
- If received on a non-root port, an alternative Root Path must be chosen and the Max Age timer is immediately expired so that a new Root Port can be found.
Configuring BackboneFast
- For BackboneFast to function correctly, it needs to be enabled on all switches in the network.
- Use the following global configuration command:
Switch(config)#spanning-tree backbonefast
Verifying configuration
Switch#show spanning-tree backbonefast
BackboneFast is enabled
References:
- Using PortFast and Other Commands to Fix Workstation Startup Connectivity Delays – Cisco Systems
- Understanding and Configuring the Cisco UplinkFast Feature – Cisco Systems
- Understanding and Configuring Backbone Fast on Catalyst Switches- Cisco Systems
This entry is not an authoritative guide. These are merely notes and rehash of the primary text materials and resources that I use. For a thorough guide of the BCMSN course, consider purchasing Building Cisco Multilayer Switched Networks (BCMSN) (Authorized Self-Study Guide) (4th Edition)by Richard Froom, Balaji Sivasubramanian, and Erum Frahim and CCNP BCMSN Official Exam Certification Guide (4th Edition) by Dave Hucaby ; as well as following the links on the reference section of this entry.
