When we configure the standard Spanning Tree Protocol on Layer 2 Switches, the STP Convergence process takes 50 seconds as a result of a link error. We can reduce this downtime with UplinkFast (UF) up to 20 seconds.
How to Enable Spanning Tree UplinkFast on Layer 2 Switch
As you know, Spanning Tree UplinkFast, BackboneFast, and PortFast are Cisco-specific. The purpose of configuring the Spanning Tree Protocol on Layer 2 Switches is to prevent loops in the network.
The Spanning Tree UplinkFast feature must be enabled on a Switch with one Blocked Port. The reason we do this is to allow Blocked Port to enter Forwarding Mode immediately as a result of a link error. Therefore, this feature will reduce the downtime of 50 seconds to 20 seconds.
In our previous articles, we have examined the PortFast Configuration and Root Bridge Configuration. In this article, we will also investigate the Uplink Fast configuration on Layer 2 Switches.
How to Setup UplinkFast in GNS3
First, you need to add Layer 2 Switch to GNS3 for configuration. For additional information, Packet Tracer does not support features such as UplinkFast and BackboneFast.
To enable UplinkFast, follow the steps below.
Step 1
Open Graphical Network Simulator-3 and create a new project for UF.
Step 2
In GNS3, create a topology like the one below. Also, configure TCP/IP for VPCS computers.
Step 3
Check the Spanning Tree Protocol configuration of Cisco Switches on the topology and select Root Bridge Switch to enter the Port States.
Cisco Switch SW1 shows that the spanning-tree command output appears to be the Root Bridge.
Step 4
At the Switch SW2 CLI prompt, execute the show spanning-tree command and note the Port States as shown below.
Step 5
In the same way, note Cisco Switch SW3 Port States.
Step 6
Start a continuous Ping from Lenovo PC to HP PC before enabling UplinkFast.
Step 7
Unplug the cable between SW1 and SW2 while continuously pinging from the Lenovo PC to the HP PC.
Step 8
STP Convergence takes 50 seconds, as shown. That’s why we can reduce this time by 30 seconds by enabling STP UplinkFast on a Switch with a Blocked Port.
Step 9
Since SW2 has one Blocked Port, we will enable Uplink Fast on this Switch. Open the SW2 CLI command prompt and execute the following command on the Switch.
SW2# conf t SW2(config)# spanning-tree uplinkfast SW2(config)# end SW2#
Step 10
After enabling the Uplink Fast feature on the Switch, verify that it is enabled by using the show spanning-tree summary command.
Step 11
The UplinkFast process is straightforward, as shown. Now, start the Ping process from Lenovo PC to HP PC again to verify how Uplink Fast works.
Then, disconnect the cable between SW1 and SW2 again.
Step 12
The STP Convergence process was completed in almost 20 seconds. If you examine the image below, you can better understand the benefit of enabling Uplink Fast on the Switch.
Step 13
Finally, when you reconnect the cable between SW1 and SW2, you can see that Ping continues without interruption.
Show Commands
SW2#show spanning-tree summary
Switch is in pvst mode
Root bridge for: none
Extended system ID is enabled
Portfast Default is disabled
PortFast BPDU Guard Default is disabled
Portfast BPDU Filter Default is disabled
Loopguard Default is disabled
EtherChannel misconfig guard is enabled
Configured Pathcost method used is short
UF is enabled
BackboneFast is disabled
Name Blocking Listening Learning Forwarding STP Active
---------------------- -------- --------- -------- ---------- ----------
VLAN0001 1 0 0 3 4
---------------------- -------- --------- -------- ---------- ----------
1 vlan 1 0 0 3 4
Station update rate set to 150 packets/sec.
UF statistics
-----------------------
Number of transitions via UF (all VLANs) : 0
Number of proxy multicast addresses transmitted (all VLANs) : 0
SW2#
SW2#show spanning-tree detail
VLAN0001 is executing the ieee compatible Spanning Tree protocol
Bridge Identifier has priority 49152, sysid 1, address 002c.78f0.2f00
Configured hello time 2, max age 20, forward delay 15
Current root has priority 32769, address 002c.785d.8700
Root port is 1 (GigabitEthernet0/0), cost of root path is 3004
Topology change flag not set, detected flag not set
Number of topology changes 3 last change occurred 00:02:02 ago
from GigabitEthernet0/1
Times: hold 1, topology change 35, notification 2
hello 2, max age 20, forward delay 15
Timers: hello 0, topology change 0, notification 0, aging 300
UF enabled
Port 1 (GigabitEthernet0/0) of VLAN0001 is root forwarding
Port path cost 3004, Port priority 128, Port Identifier 128.1.
Designated root has priority 32769, address 002c.785d.8700
Designated bridge has priority 32769, address 002c.785d.8700
Designated port id is 128.1, designated path cost 0
Timers: message age 1, forward delay 0, hold 0
Number of transitions to forwarding state: 1
Link type is shared by default
BPDU: sent 31, received 272
Port 2 (GigabitEthernet0/1) of VLAN0001 is alternate blocking
Port path cost 3004, Port priority 128, Port Identifier 128.2.
Designated root has priority 32769, address 002c.785d.8700
Designated bridge has priority 32769, address 002c.78f0.1500
Designated port id is 128.2, designated path cost 4
Timers: message age 2, forward delay 0, hold 0
Number of transitions to forwarding state: 1
Link type is shared by default
BPDU: sent 2, received 308
Port 3 (GigabitEthernet0/2) of VLAN0001 is designated forwarding
Port path cost 3004, Port priority 128, Port Identifier 128.3.
Designated root has priority 32769, address 002c.785d.8700
Designated bridge has priority 49153, address 002c.78f0.2f00
Designated port id is 128.3, designated path cost 3004
Timers: message age 0, forward delay 0, hold 0
Number of transitions to forwarding state: 1
Link type is shared by default
BPDU: sent 301, received 0
Port 4 (GigabitEthernet0/3) of VLAN0001 is designated forwarding
Port path cost 3004, Port priority 128, Port Identifier 128.4.
Designated root has priority 32769, address 002c.785d.8700
Designated bridge has priority 49153, address 002c.78f0.2f00
Designated port id is 128.4, designated path cost 3004
Timers: message age 0, forward delay 0, hold 0
Number of transitions to forwarding state: 1
Link type is shared by default
BPDU: sent 301, received 0
SW2#
SW2#
*Sep 12 13:31:34.053: %SPANTREE_FAST-7-PORT_FWD_UPLINK: VLAN0001 GigabitEthernet0/1 moved to Forwarding (UF).
*Sep 12 13:31:52.253: %SPANTREE_FAST-7-PORT_FWD_UPLINK: VLAN0001 GigabitEthernet0/0 moved to Forwarding (UF).
SW2#
SW2#show spanning-tree uplinkfast
UF is enabled
Station update rate set to 150 packets/sec.
UF statistics
-----------------------
Number of transitions via UF (all VLANs) : 2
Number of proxy multicast addresses transmitted (all VLANs) : 0
Name Interface List
-------------------- ------------------------------------
VLAN0001 Gi0/0(fwd), Gi0/1
SW2#
SW2#show spanning-tree
VLAN0001
Spanning tree enabled protocol ieee
Root ID Priority 32769
Address 002c.785d.8700
Cost 3004
Port 1 (GigabitEthernet0/0)
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Bridge ID Priority 49153 (priority 49152 sys-id-ext 1)
Address 002c.78f0.2f00
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Aging Time 300 sec
UF enabled
Interface Role Sts Cost Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
Gi0/0 Root FWD 3004 128.1 Shr
Gi0/1 Altn BLK 3004 128.2 Shr
Gi0/2 Desg FWD 3004 128.3 Shr
Gi0/3 Desg FWD 3004 128.4 Shr
SW2#
How to Enable Uplink Fast ⇒ Video
You can watch the video below to activate STP UplinkFast and also subscribe to our YouTube channel to support us!
Conclusion
Configuring Uplink Fast for the standard Spanning Tree protocol on L2 Switches is a beneficial process. If your Switches do not support Rapid STP, you should definitely enable UplinkFast to improve performance in the Standard STP configuration. Thanks for following us!