cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3246
Views
5
Helpful
9
Replies

Spanning tree: Designated Port

taps11taps11
Level 1
Level 1

Hi Guys,

I need your help, l was working on the question below but can't seem to understand the answer given. Please refer to the exhibt below.

Question:  Which Switch provides the Spanning tree designated port role for the network segment that services the printers.

Thanks, Taps

STP.jpg

9 Replies 9

cadet alain
VIP Alumni
VIP Alumni

Hi,

This is how I would do:

1) determine root bridge: here it is sw1 as it has the lowest priority and so all its ports are designated ports

2) determine root port on each non-root bridge: we assume all links are same speed so each port is same cost

----> on sw3: direct connection to sw1 and same on sw4

3) on the segment with the hub between sw3 and sw4 which has the designated port?

----> same method as for root port and so this is sw3 which is the designated bridge.

Regards.

Alain.

Don't forget to rate helpful posts.

Thanks Alain, that makes so much sense. My problem was comparing the Mac addresses on the Switch 3 and Switch 4 segment since they have the same priority. I wasn't aware of the rule that when you are comparing Mac addresses you read from left to right comparing one digit at a time and as soon as soon as there is a difference you pick the lower one and that becomes the designated port without comparing the rest of the digits. So comparing the two:

Switch 3:     0010.7bcc.733a

Switch 4:     0010.7bcc.7347

Switch 3 wins because 3 is lower than 4, so thats how it gets the designated port role.

Please confirm if this reasoning is correct.

Thanks,

Taps

Hi,

Switch 3 wins because 3 is lower than 4, so thats how it gets the designated port role.

Not correct!

To choose DP on a segment you follow the same rules you use to choose the RP.

So the priority and mac address have nothing to do with it, priority is for the root bridge election and mac address is a tie-breaker.

Regards.

Alain.

Don't forget to rate helpful posts.

Hi Alain,

I thought l had this nailed and good to go but l'm getting more and more confused now. Switch1 is the Root Switch by virtue of the lower priority,so all its ports are designating. The other end of the cable on Switch 3 and Switch 4 are Root ports. Then we need to determine the designating port on the segment with the hub between Switch 3 and 4. The selection is based on the port with the best [lower] cost to the Root bridge but since we assume they have the same cost then we'll use the Bridge priority as the tie-breaker. But again they have the same priority so thats why we end up comparing the mac addresses and leaving Switch 3 as the winner and switch 4 end becomes non-desginating [blocking].

How is that explanation?

Thanks, Taps

Hi,

"To win the right to be the DP, a switch must send the Hello with the lowest advertised cost onto  the segment"

"When the cost is a tie, STP uses the same tiebreakers to choose the DP as when choosing an RP: lowest forwarder’s bridge ID, lowest forwarder’s port priority, and lowest forwarder’s port  number"

So the switch priority is never used but the sender port priority.

But here the cost is same and you're right the bridge id is a tie and the lowest wins that is sw3, forget my previous answer I was completely out

of my mind.

Regards.

Alain.

Don't forget to rate helpful posts.

Hello Alain,

Allow me to join the discussion.

When I explain STP to my students, I do it in the following way:

  • The root port on a switch is the port that receives the best BPDUs from among all received BPDUs
  • The designated port is the port that sends the best BPDU on the segment

Now, it boils down which BPDU is better - how should the BPDUs be compared to each other. To compare BPDUs, you compare the STP "attributes" indicated in the BPDUs in a predefined order until you arrive at the first attribute that differs in its value. The BPDU containing the lower value of the attribute is better. The attributes compared and their sequence is as follows:

  1. Root Bridge ID (comprising of three parts: configurable Bridge Priority, Extended System ID, Bridge MAC)
  2. Total Root Path Cost
  3. Sender Bridge ID (comprising of three parts: configurable Bridge Priority, Extended System ID, Bridge MAC)
  4. Sender Port ID (comprising of two parts: configurable Port Priority, Port Index)
  5. Receiver Port ID (comprising of two parts: configurable Port Priority, Port Index)

The Step 5 is seldomly used but is necessary in networks with shared segments or when interfacing an MSTP region. Once again, the lower value of an attribute is better.

Note that depending on the actual topology, you may need to go down to Step 4 or even 5 to determine the root or the designated port. For example:

  • If a non-root bridge has two or more equal root cost paths through different upstream switches, it will choose the port connected to the upstream switch with the lower Sender Bridge ID as its root port (Step 3, because RBID and RPC are the same)
  • If a non-root bridge has two or more equal root cost paths through the same upstream switch, it will choose the port that receives the BPDUs having the lowest Sender Port ID as its root port (Step 4, because RBID, RPC and SBID are the same)
  • If a non-root bridge has two or more equal root cost paths through a common hub connected to a single upstream switch, it will choose its own port with the lowest Port ID as the root port (Step 5, because RBID, RPC, SBID and SPID are the same)
  • If a bridge is connected to a hub (a shared segment) via two or more ports, it will choose the port sending the better BPDUs as the designated port (Step 4)

My two cents...

Best regards,

Peter

Hi Peter,

As always you posted a very clear and useful explanation.

Regards.

Alain.

Don't forget to rate helpful posts.

Thanks for the help Guys, Its very clear now. I appreciate the help.

Taps

Hi Alain,

You are very kind. Thank you!

Best regards,

Peter

Review Cisco Networking for a $25 gift card