cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1392
Views
0
Helpful
6
Replies

STP port roles and states

trane.m
Level 1
Level 1

Hi,

I'm trying to learn enough to be able to get a CCNA.

 

Spanning Tree Protocol has 5 port states:

Disabled, blocking, listening, learning and forwarding.

and 3 port roles:

Root port, designated port and blocking port

It's difficult for me to figure out the differences and connections between the STP port roles and states.

Can all port roles be in all port states? Can all port states have all port roles?

Examples:
A designated port in a forwarding state is blocked/disabled for some reason. Which states does it go through, before it is 'stable'?

A blocking (in a disabled/blocking state, i assume?) port stops receiving BPDUs, so it (eventually) enters the forwarding state, and starts sending BPDUs. Which roles and states does it go through?

Is it possible to have a root port in anything else than a forwarding state?

What port role does a port in a listening state have?

What port role does a port in a learning state have?

 

I hope you understand. I don't see the connection between states and roles. I know what states are and i know what roles are.

I tried finding an answer to this for some hours, but couldn't. Hopefully, someone can help me understand

2 Accepted Solutions

Accepted Solutions

Jon Marshall
Hall of Fame
Hall of Fame

 

The port role describes the function of the port in the L2 loop free topology and the port states are how STP transitions ports to their roles. 

 

So for a port to end up as root or designated (which are both in a state of forwarding) it has to go through all the states from the disabled through to forwarding to ensure no loops at L2. 

 

To answer your specific questions - 

 

if a blocked port becomes unblocked for whatever reason before it can forward traffic it has to go through the listening and learning states. 

 

Yes root ports should always be forwarding.

 

Ports in listening and learning are still in the blocking role because STP is still trying to work out what role to assign to that port. 

 

Jon

 

View solution in original post

 

Yes a blocking port can be in any of the blocking, listening and learning states. 

 

Yes root ports and designated ports should always be forwarding. 

 

If a port transitions to forwarding then it can only be because it has become a root or designated port as you say. 

 

One last point, the above applies to the original STP especially the port states and they have been modified with RSTP so just be aware of that in your studies. 

 

Jon

View solution in original post

6 Replies 6

Port status is for forward learn mac address frame 

Port role is port behaive for send receive superior bpdu.

I don't understand what you're trying to tell me, but thanks for the effort.

klklklklkl.png

My note to understand STP cool/status

as I mention before the STP BPDU decided which port will be Root Designated or Alternate.

so in flow we start from blocking, the SW start send/receive BPDU and elect Root Bridge Root port and Designated port and finally alternate port.

if the port is elect as Root then it will MUST be pass listening learning and finally be forward (forward for traffic)

if the port is elect as designated then it will MUST be pass listening learning and finally be forward (forward for traffic)

 

if the port is elect as alternate then it will stay in Blocking  status.

Jon Marshall
Hall of Fame
Hall of Fame

 

The port role describes the function of the port in the L2 loop free topology and the port states are how STP transitions ports to their roles. 

 

So for a port to end up as root or designated (which are both in a state of forwarding) it has to go through all the states from the disabled through to forwarding to ensure no loops at L2. 

 

To answer your specific questions - 

 

if a blocked port becomes unblocked for whatever reason before it can forward traffic it has to go through the listening and learning states. 

 

Yes root ports should always be forwarding.

 

Ports in listening and learning are still in the blocking role because STP is still trying to work out what role to assign to that port. 

 

Jon

 

Hi Jon,

 

Thanks for your answer, that made sense! Especially that last line.

 

If you would help me by confirming i understood correctly:

A port with the blocking port role can be in the disabled, blocking, listening and learning states?

A port with the root port role or designated port role can only be in a forwarding state?

 

And by my assumptions you could also say that disabled, blocking, listening and learning states are always in a blocking port role, but if they change to forwarding, the port role will also change to either root or designated. Correct?

 

Yes a blocking port can be in any of the blocking, listening and learning states. 

 

Yes root ports and designated ports should always be forwarding. 

 

If a port transitions to forwarding then it can only be because it has become a root or designated port as you say. 

 

One last point, the above applies to the original STP especially the port states and they have been modified with RSTP so just be aware of that in your studies. 

 

Jon

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card