11-26-2012 11:15 AM - edited 03-07-2019 10:15 AM
Hi, i´m Juan from Argentina
I was reading at very granular detail about STP, to my CCIE Written Cert, and i have one scenario where i don´t know how STP works.
If i have one 2 L2 ring, STP converge in the midle of the ring, one switch has his port in blocking, and the another has his port in Designated.
If some stretch of the ring is broke, both switch must negociate a new relationship between them.
After the Max Age timer, the port will be in Listening State. Can a port in listening state send bpdus to another switch to exchange stp information, to see if own port will become Forwarding or newly blocking port?
Thanks!
Juan
11-29-2012 03:55 PM
Hello Juan,
Can a port in listening state send bpdus to another switch to exchange stp information, to see if own port will become Forwarding or newly blocking port?
Yes, absolutely correct. In fact, in plain STP, the Configuration BPDUs are sent from all port roles/states except from:
Specifically, if you have a Designated Listening port, it is sending and receiving BPDUs.
Best regards,
Peter
11-30-2012 09:08 AM
Thanks Peter, i´m thinking that the Root port, before to be Root Port must send BPDUs in Listening state too, to negotiate with his neighbor.
After to be a RP, doesn´t send more bpdu anymore.
11-30-2012 12:43 PM
Hello Juan,
i´m thinking that the Root port, before to be Root Port must send BPDUs in Listening state too, to negotiate with his neighbor.
Not entirely true... There is really no "negotiation" in STP, with the "negotiation" meaning both parties exchanging information before arriving at a decision. A Root Port is defined simply as a port that receives the best BPDUs. Note that this definition does not require sending any BPDUs at all. If a port in Listening state receives a BPDU before it is able to send its own BPDU, and the received BPDU is the best from among all other BPDUs received on different ports, then this port can be immediately declared as Root Port with no need to send anything.
Does this make sense? Please feel free to ask further.
Best regards,
Peter
11-30-2012 05:20 PM
Yes, i´m agree. This discution is very granular jeje.
The Root Port doesn´t send BPDU, but this port (before become RP) send BPDU to "negotiate" his state during Listening & Learning state (at this states, the port isn´t Root Port even).
The another detail is, when one port receive a better BPDU, first will be pass across List/Lear state, not inmedialy to Forward. Do you understand?
Thanks from Argentina.
Juan
12-01-2012 03:52 AM
Hello Juan,
The Root Port doesn´t send BPDU, but this port (before become RP) send BPDU to "negotiate" his state during Listening & Learning state (at this states, the port isn´t Root Port even).
I agree that a port might be sending BPDUs before finding out it is a Root Port - but from the moment a port knows it is the Root Port, it will stop sending BPDUs. There is nothing to "negotiate" here.
One of the misunderstandings about STP is that as soon as a port is connected, it enters its default role and state which would be Designated Listening in case of legacy STP. There is no such thing as a port in unknown role. A port always starts in Designated role and only if it finds out that the role is inappropriate, it modifies it.
So when you connect a new port, it immediately becomes Designated Listening and is free to send BPDUs. However, if it receives a BPDU sooner than it sends its own BPDU, and the received BPDU is the best from among all received BPDUs on all ports, this port moves from Designated Listening to Root Listening and will cease sending all BPDUs. No BPDU would be sent at all in this scenario.
when one port receive a better BPDU, first will be pass across List/Lear state, not inmedialy to Forward. Do you understand?
Juan, the basic idea behind not sending BPDUs in STP is that you do not need to send BPDUs if they would be considered inferior to other BPDUs. As you may know, the entire STP is based on the ability to compare any two BPDUs and to select the superior one. Every process in STP is based on selecting the superior BPDU. Therefore, sending inferior BPDUs is useless as no one is going to care about them.
If you think about the port roles carefully then both Non-Designated and Root port roles are ports which would be sending inferior BPDUs. A Non-Designated port has become Non-Designated precisely because it was sending inferior BPDUs on the segment and there is someone else sending better BDPUs than its own. A Root port would be sending inferior BPDUs because the Root Path Cost value in these BPDUs would be larger than the Root Path Cost in BPDUs sent from the "upstream switch" this Root Port leads to (the "upstream" switch is closer to the root switch than we are, that is why we have chosen the port towards it as our Root Port).
So the sending and non-sending of BPDUs is primarily a matter of the port role, not a matter of the port state. Designated ports send BPDUs. Root and Non-Designated ports do not. In addition, the Non-Designated port role is always tied to Blocking state (i.e. a Non-Designated port may never be in other state than Blocking), so this gives a false feeling that sending of BPDUs is related to port states. In fact, however, it is the port role that determines if it is necessary to send BPDUs.
Best regards,
Peter
09-27-2023 09:42 PM
Great answer. I fully better understand how STP works. Thanks.
12-01-2012 01:20 PM
Hi Juan,
Just to add to the already perfect reply and in answer to this question:
'The another detail is, when one port receive a better BPDU, first will be pass across List/Lear state, not inmedialy to Forward.'
This is correct. Even though you are receiving a better BPDU you still need to 'listen' to the topology and 'learn' the addresses of what you're connected to on that port.
Thanks,
Adam
Sent from Cisco Technical Support iPad App
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