Usage Scenario
On a complex Layer 2 network, STP/RSTP/MSTP can be configured on devices to prevent or break loops.
To enable STP/RSTP/MSTP, run the
stp enable command. The devices running STP/RSTP/MSTP exchange information to discover loops on the network and block some interfaces to trim the ring topology into a loop-free tree topology. This prevents packet replication and circular propagation and device performance deterioration.
Spanning tree calculation consumes system resources. Therefore, run the
stp disable command to disable STP/RSTP/MSTP on devices or interfaces that do not need to participate in spanning tree calculation.
Precautions
- STP/RSTP/MSTP must be enabled on all interfaces that participate in spanning tree calculation. Otherwise, a loop may occur.
- If STP and VPLS multi-homing (VPLS multi-homing enables data packets to be blocked on the backup PE's AC interface, preventing loops) have been deployed, the AC interfaces of both the master and backup PEs may be blocked because the backup PE's AC interface does not block Layer 2 protocol packets.
- If the undo stp enable or stp disable command is run in the MSTP process view, the STP/RSTP/MSTP function in the MSTP process is disabled, which may cause a loop in the MSTP process.