Enabling the spanning tree feature in STP/RSTP/MSTP mode

Step

Command

Remarks

1. Enter system view.

system-view

N/A

2. Enable the spanning tree feature.

stp global enable

By default, the spanning tree feature is disabled globally.

3. Enter Layer 2 Ethernet interface or Layer 2 aggregate interface view.

interface interface-type interface-number

N/A

4. (Optional.) Enable the spanning tree feature for the port.

stp enable

By default, the spanning tree feature is enabled on all ports.