1

In this topology, we are going to see how Spanning Tree Protocol (STP) selects forwarding port if multiple links present on same segment using packet tracer

First create a topology like this with two switch connect them with cross cable.Here i have selected Fa0/2,Fa0/4,Fa0/6 in switch A and Fa0/12,Fa0/20,Fa0/18 in Switch B connected with cross cable.
How Spanning Tree Protocol Works If Multiple Links on Same Segment


Port Fa0/2 of switch A is Connected to Fa0/12 of Switch B,
Fa0/4 of switch A isconnected to Fa0/20 of switch B and
Fa0/6 of switch A is connected to Fa0/18 of switch B

Once, we place a switch in packet tracer working area the switch automatically starts and STP will be enabled by default.After we connects two switches STP automatically choose the root switch and it will block redundant links by keeping only one active to avoid loop.

STP uses lowest bridge ID to choose root switch.Here, Both switches have same Priority so STP will go for MAC address for root switch selection,

Switch A MAC address : 0002.175B.AD32
Switch B MAC address : 0001.635C.E32B


Switch B has the lowest MAC address than Switch A.So, the switch B will become root switch.

After selecting root switch, then STP will block redundant link that cause loop using received BPDU information. Only one link with lowest port cost will be selected as forwarding port, other than this will be blocked.If current active links fails then STP selects port with lowest port cost of remaining ports.If port costs are same for all links then, port number will be used to select forwarding port.

In this topology port cost of all ports are same, that is 19 (100 Mbps).So, STP will choose forwarding port by using lowest port number of root switch.Here, switch B is root switch and lowest port number of root switch is Fa0/12. Here, Interface Fa0/12 is connected to interface Fa0/2 of switch A.So, interface Fa0/2 will be root port and other ports in switch A that connects switch B will be in blocking state, that is Fa0/4 and Fa0/6 of Switch A.

All ports in root switch will be designated port.Here, Fa0/12, Fa0/20 and Fa0/18 of switch B will be designated ports.

Choosing Path by Spanning Tree

This how STP selects ports if redundant links connected on same segment.
Link status by giving command in Privileged mode,

Switch#Show Spanning-tree
How Spanning Tree Protocol Works If Multiple Links on Same Segment




Now, we see what will happen if current forwarding port fails.


For that, I am going to shutdown interface Fa0/12 of switch B.Give this command in global configuration mode of switch B to shudown the port Fa0/12.


Switch(config)#interface fastEthernet 0/12
Switch(config-if)#shutdown


After giving this command STP selects forwarding port by lowest cost port of root Switch..If cost is same then the link with lowest port number from other links that is connected to switch A will be selected.For that, port of switch A that is connected to the lowest cost port of switch B will be set as root port.

STP Path calculation after Link was Down


Here,
Port Fa0/12 is down,remaining ports that is connected to switch A is Fa0/20 and Fa0/18.

Fa0/20 is connected to Fa0/4 port of switch A Fa0/18 is connected to Fa0/6 port of switch A

Cost of all links are same,so Spanning Tree Protocol will choose forwarding port from switch B with lowest port number.Fa0/18 will be selected as forwarding port,Fa0/18 is connected with Fa0/6 of switch A.Then, the port Fa0/6 of switch A will be root port and port Fa0/18 will be designated port.

Fa0/20 port of switch B will be designated port and Fa0/4 will be in blocking state(Alternate Port).

Link status by giving command in Privileged mode,

Switch#Show Spanning-tree
How Spanning Tree Protocol Works If Multiple Links on Same Segment





Changing Forwarding port manually


We can manullay choose forwarding port by reducing the speed of the port that we dont want to be a forwarding port.100 Mbps is default speed in all ports.we have to options one is 100 Mbps or 10 Mbps.Cost of 100 Mbps is 19 and cost of 10 Mbps is 100.

Without shutdown we can make the link that we dont want be primary forwarding port to secondary port by setting speed to lower value.If we set to 10 Mbps to Fa0/12, the cost of this port will be 100.


Switch(config)#interface fastEthernet 0/12
Switch(config-if)#speed 10
Switch(config-if)#exit


Manually Choosing Path by Administrator in STP


Link status by giving command in Privileged mode,

Switch#Show Spanning-tree

Changing Forwarding port manually STP


Now, STP will go for other lowest cost ports for port selection.Here, other ports are Fa0/20 and Fa0/18 and this post cost are same, STP will choose lowest port number from this two ports.That is Fa0/18.Fa0/6 of switch A will be root port.


How Spanning Tree Protocol Works If Multiple Links on Same Segment STP Full Video





Post a Comment

  1. Social media platforms, the digital agora, amplify voices and forge connections, turning the internet into a dynamic space for social interaction and expression.123moviesfree

    ReplyDelete

 
Top