Jump to content

STP ports

johnyb98

Hello everyone.

 

I have some questions on STP ports states and data sent via these ports.

 

It is about two neighbor switches. Let's say switches S1 and S2 are connected with only one cable, in their f0/1 port each.

These ports, f0/1 is the root port for each.

 

Then, f0/5 of each is the designated ports.

 

Now let's say S1 wants to send some data to S2. Since f0/5 of S1 has no cable to connect to S2, how are data being exchanged between them? I do not think that data are being exchanged via f0/1 ports, because f0/1 ports are not ports for exchanging data. They are root ports. Not forwording/designated ports that make this job.

 

Thank you for your time!

 

Link to comment
Share on other sites

Link to post
Share on other sites

In this case only 1 device in the STP topology will be elected the root bridge but regardless the root or designated doesn't eliminate that from being able to pass data. They are connected over a single port sure but they still pass normal data.

Current Network Layout:

Current Build Log/PC:

Prior Build Log/PC:

Link to comment
Share on other sites

Link to post
Share on other sites

Thank you for your answer.

 

Of course, from my questions on topic, you have understood that I have not yet understood STP ports states, and in general STP.

 

So, according to your answer, I guess that in the state every port that we have joined in STP, regardless its state, data finally will be transmitted via port that the cable is connected to, no matter if it is a root port and not a forwarding port. It is like in a switch, data first meets forwarding port, then goes to root port (cable) and then goes to next hop switch. Is that right?

 

An example with switches, ports, ports states, cabling and all this stuff would be perfect (of course if you have some time).

Link to comment
Share on other sites

Link to post
Share on other sites

15 minutes ago, johnyb98 said:

Thank you for your answer.

 

Of course, from my questions on topic, you have understood that I have not yet understood STP ports states, and in general STP.

 

So, according to your answer, I guess that in the state every port that we have joined in STP, regardless its state, data finally will be transmitted via port that the cable is connected to, no matter if it is a root port and not a forwarding port. It is like in a switch, data first meets forwarding port, then goes to root port (cable) and then goes to next hop switch. Is that right?

 

An example with switches, ports, ports states, cabling and all this stuff would be perfect (of course if you have some time).

Correct, you go through the STP states and elect the root bridge and so on and then when everything is settled (45 seconds is the default for STP) then you'll start passing data traffic. That's why you want to set portfast on edge ports and use RSTP so they don't go through the standard STP phases before forwarding data resulting in DHCP timing out and go right to forwarding data.

For the path data takes it depends on the exact layout as it can vary a bit depending on where it's coming in, giong to, and (if L3 is involved) where the L3 interface is as well. In a triangle topology of:

         ------- Switch1 --------

         |                              |

         |                              |

     Switch2 ----------- Switch3

 

Let's say standard STP (802.1d) here, nothing advanced (802.1w) and that Switch1 is root because of priority configured.

Switch2 and Switch3 >>>> Switch 1 will be Root

Switch1 >>>>>>> Switch2 and Switch3 will be Designated

Switch2 <<<<>>>>> Switch3 will be Blocking on one side with the other being a designated port

 

Now let's say Switch1 <<<<>>>> Switch2 goes down. STP will reconverge and go through the states and we'll end up like this:

                  Switch1 --------

                                        |

                                        |

     Switch2 ----------- Switch3

 

Switch2 >> Switch3 is now a Root Port

Switch3 << Switch2 is now Designated

Switch3 >> Switch 1 is a Root Port

Switch3 << Switch1 is still a Designated port

 

The above assumes equal cost links across the network. If we had unequal cost links they things might shift a bit in the original example. You'll also have up to 30 to 50 seconds of convergence time for anything coming in off switch2 depending on the timers in STP as well to detect the topology change.

Current Network Layout:

Current Build Log/PC:

Prior Build Log/PC:

Link to comment
Share on other sites

Link to post
Share on other sites

Awesome!! Thank you very much for your time and writing. This all is amazing helpful. Thank you again.

 

Now, a last question that I cannot understand days now.

I see in many videos and web pages diagrams and topologies, neighbor switches cost to be just one cost. What I mean?

If two neighbor switches are connected in same bps ports, of course there I understand that we have one cost. Same cost because ports are same bandwidth. But, what if the connection is in different bps ports?

 

See, in following image:

 

STP.jpg.d7f1f6560fdce966b74e01672517df95.jpg

 

In this topology, I do not understand if I make any mistake in cost between CoreSwitch and DSW2. In this cable connection, in CoreSwitch, port is a fast ethernet port (100Mbps), and in DSW2 cable goes on a Gbps port.

So:

Clockwise : cost is 4

Non-clockwise : cost is 19.

 

Am I wrong? And if I am wrong, could you please give me the explanation?

 

Link to comment
Share on other sites

Link to post
Share on other sites

2 minutes ago, johnyb98 said:

-snip-

Ah, they are trying to trick you, remember the ports will negotiate to the lower of the speeds so even though they are Gigabit ports the link is still fast ethernet speed and use that cost of 19.

Current Network Layout:

Current Build Log/PC:

Prior Build Log/PC:

Link to comment
Share on other sites

Link to post
Share on other sites

New question came up.

 

Why, in stp, other link of root port must be a designated port?

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, johnyb98 said:

New question came up. Why in stp othe link of root port must be a designated port?

They are designated because they are the lowest cost and the other side of the link is root because that's the direction to the root bridge.

Current Network Layout:

Current Build Log/PC:

Prior Build Log/PC:

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×