12-22-2011 07:37 AM - edited 03-07-2019 04:01 AM
Does STP use something similar to a routing protocol.Is the cost to the root switch based on metrics and link states ? I understand how the root switch Is chosen using the mac address /8 byte combo but I don't understand how STP calculates cost when choosing a root port.
Solved! Go to Solution.
12-22-2011 07:47 AM
hi,
in the port election process, ports get assigned a port cost and port priority.
the lower the port cost and priority the more preferable the port. the cost is an inverse reflection of the bandwith of the port.
the current switches use the following port costs:
10Gbps = 2
1Gbps = 4
100Mbps = 19
10Mbps = 100
the port priority defaults to 32.
port costs are calculated from the root switch.
if a switch tries to choose the root port it will always take the path with the lowest accumulated path cost to the root.
florian
12-22-2011 08:47 AM
For the Root Switch election only the Bridge ID Matters . Bridge ID is the combination of Priority and Burnt-in Switch Mac address if it is CST (Common Spanning tree) or priority + Vlan ID + Burnt in Switch MAC in case of PVST.
Hope this helps.
-Vijay
12-22-2011 07:47 AM
hi,
in the port election process, ports get assigned a port cost and port priority.
the lower the port cost and priority the more preferable the port. the cost is an inverse reflection of the bandwith of the port.
the current switches use the following port costs:
10Gbps = 2
1Gbps = 4
100Mbps = 19
10Mbps = 100
the port priority defaults to 32.
port costs are calculated from the root switch.
if a switch tries to choose the root port it will always take the path with the lowest accumulated path cost to the root.
florian
12-22-2011 07:52 AM
Thanks! This clears up a lot.I don't understand why the ICND2 cert. book doesn't mention this.It helps a lot In making sense of whats going on.
12-22-2011 08:01 AM
there are a couple of things the swich does when choosing a root or a designated port.
for instance if the port costs of the switch are all the same(e.g. 24 port gig switch) then the swich will choose the neighboring switch with the lowest switch ID.
if multiple paths all go through the same neighboring switch it will choose the port with the lowest port priority and if all have the same port priority it will take the physically lowest numbered port on the switch.
and these steps are pretty much the same when choosing the designated port.
florian
12-22-2011 08:09 AM
Thanks for your help.I have one last question If thats Ok .Does bandwidth factor In when choosing the root switch or Is the choice of root switch a bit like a lottery.
12-22-2011 08:47 AM
For the Root Switch election only the Bridge ID Matters . Bridge ID is the combination of Priority and Burnt-in Switch Mac address if it is CST (Common Spanning tree) or priority + Vlan ID + Burnt in Switch MAC in case of PVST.
Hope this helps.
-Vijay
12-22-2011 09:30 AM
Thanks for your help!
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide