Show spanning-tree
Mikdilly
Member Posts: 309
in CCNA & CCENT
When you do a show spanning-tree does the default port cost infer how many hops away you are from the root bridge, as in 19 would mean 1 hop away, 38 would mean 2 hops?
Comments
-
mikearama Member Posts: 749Nope... port cost refers to speed on the link.
100Mb/s = 19
while a 10Mb/s link has a cost of 100,
and a Gb link has a cost of 4.
It's not a question of hops, but speed. The link with the lowest cost (highest speed) is selected as root port. Course, if there's multiple links to the root bridge, then the cost is cumulative... so if the cost was 38, you know that the local link is 100Mb/s, and the link on the other side of the next hop is also 100Mb/s. 19 + 19 = 38.
MikeThere are only 10 kinds of people... those who understand binary, and those that don't.
CCIE Studies: Written passed: Jan 21/12 Lab Prep: Hours reading: 385. Hours labbing: 110
Taking a time-out to add the CCVP. Capitalizing on a current IPT pilot project. -
Mikdilly Member Posts: 309mikearama wrote:Nope... port cost refers to speed on the link.
100Mb/s = 19
while a 10Mb/s link has a cost of 100,
and a Gb link has a cost of 4.
It's not a question of hops, but speed. The link with the lowest cost (highest speed) is selected as root port. Course, if there's multiple links to the root bridge, then the cost is cumulative... so if the cost was 38, you know that the local link is 100Mb/s, and the link on the other side of the next hop is also 100Mb/s. 19 + 19 = 38.
Mike
Thanks, is there any show command on a switch that would tell you how far away from the root bridge you are?