STP ensures a loop-free network but has a slow network topology convergence speed, leading to service deterioration. If the network topology changes frequently, the connections on the STP-enabled network are frequently torn down, causing frequent service interruption. Users can hardly tolerate such a situation.
Disadvantages of STP are as follows:
Disadvantages of STP
l STP ensures a loop-free network but is slow to converge, leading to service quality deterioration. If the network topology changes frequently, connections on the STP network are frequently torn down, causing frequent service interruption.
l STP does not differentiate between port roles according to their states, making it difficult for less experienced administrators to learn about and deploy this protocol.
1. Ports in Listening, Learning, and Blocking states are the same for users because none of these ports forwards service traffic.
2. In terms of port use and configuration, the essential differences between ports lie in the port roles but not port states.
3. Both root and designated ports can be in Listening state or Forwarding state, So the port roles cannot be differentiated according to their states.
l The STP algorithm does not determine topology changes until the timer expires, delaying network convergence.
l The STP algorithm requires the root bridge to send configuration BPDUs after the network topology becomes stable, and other devices process and spread the configuration BPDUs through the entire network. This also delays convergence.
Improvements Made in RSTP
To make up for STP disadvantages, RSTP deletes three port states, introduces two port roles, and distinguishes port attributes based on port states and roles to provide a more accurate port description. This offers beginners easy access to protocols and speeds up topology convergence.
Port Roles
RSTP defines four-port roles: root port, designated port, alternate port, and backup port.

The functions of the root port and designated port are the same as those defined in STP. The alternate port and backup port are described as follows:
l From the perspective of configuration BPDU transmission:
n An alternate port is blocked after learning the configuration BPDUs sent by other bridges.
n A backup port is blocked after learning the configuration BPDUs sent by itself.
l From the perspective of user traffic
n An alternate port backs up the root port and provides an alternate path from the designated bridge to the root bridge.
n A backup port backs up the designated port and provides an alternate path from the root bridge to the related network segment.
Port states
Port states are simplified from five types to three types. Based on whether a port forwards user traffic and learns MAC addresses, the port is in one of the following states:
If a port neither forwards user traffic nor learns MAC addresses, the port is in the Discarding state.
If a port does not forward user traffic but learns MAC addresses, the port is in the Learning state.
If a port forwards user traffic and learns MAC addresses, the port is in the Forwarding state.

Configuration BPDUs
BPDU format:
Configuration BPDUs in RSTP are differently defined. Port roles are described based on the Flags field defined in STP.
Compared with STP, RSTP slightly redefined the format of configuration BPDUs.
n The value of the Type field is no longer set to 0 but 2. Therefore, the RSTP-enabled device always discards the configuration BPDUs sent by an STP-enabled device.
n The 6 bits in the middle of the original Flags field are reserved. Such a configuration BPDU is called an RST BPDU.
BPDU Processing Mode
RSTP processes configuration BPDUs differently from STP.
n When the topology becomes stable, the mode of sending configuration BPDUSs is optimized.
n RSTP uses a shorter timeout interval of BPDUS.
n RSTP optimizes the method of processing inferior BPDUs.
Rapid convergence
n Proposal/agreement mechanism
When a port is selected as a designated port, in STP, the port does not enter the Forwarding state until a Forward Delay period expires; in RSTP, the port enters the Discarding state, and then the proposal/agreement mechanism allows the port to immediately enter the Forwarding state. The proposal/agreement mechanism must be applied on the P2P links in full-duplex mode.
n Fast switchover of the root port
If the root port fails, the most superior alternate port on the network becomes the root port and enters the Forwarding state. This is because there must be a path from the root bridge to a designated port on the network segment connecting to the alternate port.
When the port role changes, the network topology will change accordingly.
n Edge ports
In RSTP, a designated port on the network edge is called an edge port. An edge port directly connects to a terminal and does not connect to any other devices.
An edge port does not receive configuration BPDUs, and therefore does not participate in the RSTP calculation. It can directly change from the Disabled state to the Forwarding state without any delay, just like an STP-incapable port. If an edge port receives bogus BPDUs from attackers, it is deprived of the edge port attributes and becomes a common STP port. The STP calculation is implemented again, causing network flapping.






