To display information about the Spanning Tree Protocol (STP), use the show spanning-tree command.
show spanning-tree [ blockedports | inconsistentports | pathcost method ]
|
blockedports
|
(Optional) Displays the alternate ports blocked by STP.
|
|
inconsistentports
|
(Optional) Displays the ports that are in an inconsistent STP state.
|
|
pathcost method
|
(Optional) Displays whether short or long path cost method is used. The method differs for Rapid Per VLAN Spanning Tree Plus (Rapid PVST+) (configurable, default is short) and Multiple Spanning Tree (MST) (nonconfigurable, operational value is always long).
|
None
EXEC mode
|
Release
|
Modification
|
|---|---|
|
4.0(0)N1(1a)
|
This command was introduced.
|
The STP port type displays only when you have configured the port as either an STP edge port or an STP network port. If you have not configured the STP port type, no port type displays.
The table below describes the fields that are displayed in the output of show spanning-tree commands.
|
Field
|
Definition
|
|---|---|
|
Role
|
Current port STP role. Valid values are as follows:
|
|
Sts
|
Current port STP state. Valid values are as follows:
|
|
Type
|
Status information. Valid values are as follows:
|
Note Display output differs slightly depending on whether you are running Rapid Per VLAN Spanning Tree Plus (Rapid PVST+) or Multiple Spanning Tree (MST).
This example shows how to display spanning tree information:
This example shows how to display the blocked ports in spanning tree:
This example shows how to determine if any ports are in any STP-inconsistent state:
This example shows how to display the path cost method:
|
Command
|
Description
|
|---|---|
|
show spanning-tree active
|
Displays information about STP active interfaces only.
|
|
show spanning-tree bridge
|
Displays the bridge ID, timers, and protocol for the local bridge on the switch.
|
|
show spanning-tree brief
|
Displays a brief summary about STP.
|
|
show spanning-tree detail
|
Displays detailed information about STP.
|
|
show spanning-tree interface
|
Displays the STP interface status and configuration of specified interfaces.
|
|
show spanning-tree mst
|
Displays information about Multiple Spanning Tree (MST) STP.
|
|
show spanning-tree root
|
Displays the status and configuration of the root bridge for the STP instance to which this switch belongs.
|
|
show spanning-tree summary
|
Displays summary information about STP.
|
|
show spanning-tree vlan
|
Displays STP information for specified VLANs.
|