The stp priority command sets a priority for a device on a spanning tree.
The undo stp priority command restores the default priority.
By default, the priority of a device on a spanning tree is 32768.
Parameter | Description | Value |
---|---|---|
instance instance-id |
Specifies the ID of a spanning tree instance. If this parameter is not specified, the configuration takes effect on a Common and Internal Spanning Tree (CIST) instance. |
The value is an integer ranging from 0 to 4094, Value 0 indicates CIST. |
priority |
Specifies the priority of a device. A smaller value indicates a higher priority. |
The value ranges from 0 to 61440. The value is an integer multiple of 4096, such as 0, 4096, and 8192. |
Usage Scenario
Priorities of devices are an important factor to calculate a spanning tree and determine root bridge selection.
On a network running STP/RSTP/MSTP, each spanning tree has only one root bridge responsible for sending Bridge Protocol Data Units (BPDUs). Because the root bridge is of great importance, it is hoped that a device with high performance and network hierarchy can be chosen as the root bridge. However, this cannot be achieved if the device has a low priority. To set a priority for the device, run the stp priority command. You can also run the stp priority command to set a low priority for devices with low performance and network hierarchy so that these devices are not selected as the root bridge. On an MSTP network, each device can be set with a unique priority in each spanning tree instance.Configuration Impact
A smaller priority value indicates a higher possibility to be selected as the root bridge.