Port Priority in STP

Answered Question
Jun 16th, 2009
User Badges:

Hello. I read that when a switch experiences a tie in regard to the cost to reach the root, the switch first uses the interfaces' Port Priority value as a tiebreaker. If the port priority values tie, the switch uses the lowest internal interface number. I have 3 trunks (Fa 05 - 7) all with cost 19 to reach root and port priority 128... Fa 0/5 is in FWD (RP).... I changed the port priority of port Fa 0/7 to 112 to break the tie in cost but port Fa 0/5 is still the RP.... is there any reason for this? Is what I read correct?. Please help.

Correct Answer by thotsaphon about 7 years 10 months ago


I'm not sure which book you have been studying. However,my first post gives you the right way.



  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 4 (1 ratings)
thotsaphon Tue, 06/16/2009 - 10:14
User Badges:
  • Gold, 750 points or more

Francisco, Hi it's me again.(grin)

We have the order operation to determine who is going be to a root bridge,which port is going to a root port/designate port/block port.

- One root bridge per network

- One root port per non-rootbridge

- One designate port per segment

It uses the following steps to find out.

1. Lowest sender BID

2. Lowest cost to root

3. Lowest sender bridge priority

4. Lowest sender port number

As per your question, F0/5 is in the forwarding state(RootPort). Right? You want to modify F0/7 to take this role. Okay let's start from here. As per rule number2. Cost is a tie. Well,we go to rule number3. What you have to do is that you have to change port priority on the upstream switch to affect this requirement.

Hopes I give you a lot of confusing things. J/K


fjcardenas-1 Tue, 06/16/2009 - 13:20
User Badges:

I'm confused. Root will announce a cost of 0 to the next switches. New example: I have 3 trunks (Fa 0/5,6,7) from SW1 to Root. To determine the Root Port we add the cost of the outgoing interfaces in the path. Since each interface I have is connected to root and they all are FE the cost is 19 so there is a tie. According to the book and by logic (if the cost is the sum of outgoing interfaces) if I change the cost of interface Fa 0/6 to 96 it should become the RP, however that doesn't happen. See the output in the attachment.

But, if I change the port cost in the root switch id does causes SW1 to choose a different RP... but it doesn't make sense since you add the cost of output interfaces (from SW1 to Root) and not the other way around.

Please help.

thotsaphon Tue, 06/16/2009 - 13:44
User Badges:
  • Gold, 750 points or more


Interface Role Sts Cost Prio.Nbr Type

---------------- ---- --- --------- -------- --------------------------------

Fa0/5 Altn BLK 19 128.5 P2p

Fa0/6 Altn BLK 19 96.6 P2p

Fa0/7 Root FWD 19 128.7 P2p

As far as I can see is that you did change the priority of F0/6. Like I said, what you can do is as follows:

0. Bring the configuration back to the first time you mentioned. F0/5 on SW-HC is in RP state.

1. Adjust a cost on f0/6 on the SW-HC.

- spanning cost 4

2. Adjust a priority on f0/6 on the upstream switch.

- spanning tree priority 96

Hopes you connected the ports like this




Am I correct? This's important. Please let me know. (grin)

If you have questions why it should be configured as above, then read my first post again. (grin)

Please let me know how things work out.



fjcardenas-1 Wed, 06/17/2009 - 05:42
User Badges:

My ports are connected as you mentioned in the Upstream Switch (I understand this is ROOT in this case) and in the SW-HC.

If I change the priority of Fa 0/7 to 112 nothing happens (fa 0/5 is still RP). But if I change the priority of Fa 0/7 to 112 in the ROOT Switch then Fa 0/7 in my SW-HC becomes RP. It works as you said (change the priority in the upstream switch).

What confuses me is why the port priority value has to be changed in the upstream switch (ROOT) and not in my SW-HC? If instead of the port priority I want to change the cost then it works by changing the cost of the interface in my SW-HC and not in ROOT.

I guess the book doesn't explain the fact that port priority has to be changed in the upstream switch.

Correct Answer
thotsaphon Wed, 06/17/2009 - 05:51
User Badges:
  • Gold, 750 points or more


I'm not sure which book you have been studying. However,my first post gives you the right way.



fjcardenas-1 Wed, 06/17/2009 - 07:50
User Badges:

Thank you.

I guess the configuration of port priority in the upstream switch is what I was missing. (not specified in the book).


This Discussion