Overview of STP/RSTP

Definition

Generally, redundant links are used on an Ethernet switching network to provide link backup and enhance network reliability. The use of redundant links, however, may produce loops, causing broadcast storms and MAC address table instability. As a result, the communication quality deteriorates, and the communication service may even be interrupted. The Spanning Tree Protocol (STP) is introduced to resolve this problem.

Related Concepts

STP has a narrow sense and a broad sense.
  • STP, in a narrow sense, refers to only the STP protocol defined in IEEE 802.1D.
  • STP, in a broad sense, refers to the STP protocol defined in IEEE 802.1D, the Rapid Spanning Tree Protocol (RSTP) defined in IEEE 802.1W, and the Multiple Spanning Tree Protocol (MSTP) defined in IEEE 802.1S.

Currently, the following spanning tree protocols are supported:

  • STP

    STP, a management protocol at the data link layer, is used to detect and prevent loops on a Layer 2 network. STP blocks redundant links on a Layer 2 network and trims a network into a loop-free tree topology.

    The STP topology, however, converges at a slow speed. A port cannot be changed to the Forwarding state until twice the time specified by the Forward Delay timer elapses.

  • RSTP

    RSTP, as an enhancement of STP, converges a network topology at a faster speed.

    In both RSTP and STP, all VLANs share one spanning tree. All VLAN packets cannot be load balanced, and some VLAN packets cannot be forwarded along the spanning tree.

    RSTP is backward compatible with STP and can be used together with STP on a network.

  • MSTP

    MSTP defines a VLAN mapping table in which VLANs are associated with multiple spanning tree instances (MSTIs). In addition, MSTP divides a switching network into multiple regions, each of which has multiple independent MSTIs. In this manner, the entire network is trimmed into a loop-free tree topology, and replication and circular propagation of packets and broadcast storms are prevented on the network. In addition, MSTP provides multiple redundant paths to balance VLAN traffic.

    MSTP is compatible with STP and RSTP. Table 1 shows a comparison between STP, RSTP, and MSTP.

    Table 1 Comparison between STP, RSTP, and MSTP

    Spanning Tree Protocol

    Characteristics

    Usage Scenario

    Precautions

    STP

    In an STP region, a loop-free tree is generated. Broadcast storms are therefore prevented, and redundancy is implemented.

    STP or RSTP is used in a scenario where all VLANs share one spanning tree. In this situation, users or services do not need to be differentiated.

    NOTE:
    • If the current switching device supports only STP, STP is recommended.

    • If the current switching device supports both STP and RSTP, RSTP is recommended.

    • If the current switching device supports STP or RSTP, and MSTP, MSTP is recommended.

    RSTP

    • In an RSTP region, a loop-free tree is generated. Broadcast storms are thereby prevented, and redundancy is implemented.
    • RSTP allows fast convergence of a network topology.

    MSTP

    • In an MSTP region, a loop-free tree is generated. Broadcast storms are thereby prevented, and redundancy is implemented.
    • MSTP allows fast convergence of a network topology.
    • MSTP implements load balancing among VLANs. Traffic in different VLANs is transmitted along different paths.

    MSTP is used in a scenario where traffic in different VLANs is forwarded through different spanning trees that are independent of each other to implement load balancing. In this situation, users or services in different VLANs are distinguished.

Purpose

After a spanning tree protocol is configured on an Ethernet switching network, it calculates the network topology and implements the following functions to remove network loops:

  • Loop prevention: The potential loops on the network are cut off after redundant links are blocked.
  • Link redundancy: When an active path becomes faulty, a redundant link can be activated to ensure network connectivity.

Benefits

This feature offers the following benefits to carriers:
  • Compared with dual-homing networking, the ring networking requires fewer fibers and transmission resources. This reduces resource consumption.

  • STP prevents broadcast storms. This implements real-time communication and improves communication reliability.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
Next topic >