Command:

set spantree root

Mode:

Switch> (enable)


Syntax:

set spantree root [secondary] [vlans] [dia network_diameter] [hello hello_time]

set spantree root [secondary] mistp-instance instances [dia network_diameter]

set spantree root [secondary] mst {instance | {[dia network_diameter] [ hello hello_time]}}


Syntax Description:

secondary

(Optional) Keyword that designates this switch as a secondary root, if the primary root fails.

vlans

(Optional) Variable that specifies the number of the VLAN; valid values are from 1 to 1005.

dia network_diameter

(Optional) Keyword that specifies the maximum number of bridges between any two points of attachment of end stations; valid values are from 2 to 7.

hello hello_time

(Optional) Keyword that specifies, in seconds, the duration between generation of configuration messages by the root switch; valid values are from 1 to 10.

mistp-instance instances

Keyword and variable that specify the instance number; valid values are from 1 to 16.

mst instance

Keyword and variable that set the forward delay time for the IST instance and all MST instances

 


Command Description:

Use the set spantree root command to set the primary or secondary root for specific VLANs of the switch or for all VLANs of the switch.


Examples:

This example shows how to set the primary root for a range of VLANs:

Console> (enable) set spantree root 1-10 dia 4

VLANs 1-10 bridge priority set to 8192
VLANs 1-10 bridge max aging time set to 14 seconds.
VLANs 1-10 bridge hello time set to 2 seconds.
VLANs 1-10 bridge forward delay set to 9 seconds.
Switch is now the root switch for active VLANs 1-6.
Console> (enable)
 

This example shows how to set the primary root for an instance:

Console> (enable) set spantree root mistp-instance 2-4 dia 4

Instances 2-4 bridge priority set to 8192
VLInstances 2-4 bridge max aging time set to 14 seconds.
Instances 2-4 bridge hello time set to 2 seconds.
Instances 2-4 bridge forward delay set to 9 seconds.
Switch is now the root switch for active Instances 1-6.
Console> (enable)
 

This example shows how to set the primary root for MST instance 5:

Console> (enable) set spantree root mst 5

Instance 5 bridge priority set to 24576.
Instance 5 bridge max aging time set to 16.
Instance 5 bridge hello time set to 2.
Instance 5 bridge forward delay set to 15.
Switch is now the root switch for active Instance 5.
Console> (enable)
 

This example shows how to set the secondary root for MST instance 0:

Console> (enable) set spantree root secondary mst 0

Instance 0 bridge priority set to 28672.
Instance 0 bridge max aging time set to 20.
Instance 0 bridge hello time set to 2.
Instance 0 bridge forward delay set to 15.
Console> (enable)
 

This example shows how to set the maximum number of bridges and the hello time of the root for MST instance 0:

Console> (enable) set spantree root mst 0 dia 7 hello 2
Instance 0 bridge priority set to 24576.
Instance 0 bridge max aging time set to 20.
Instance 0 bridge hello time set to 2.
Instance 0 bridge forward delay set to 15.
Switch is now the root switch for active Instance 0.
Console> (enable)
 

These examples show that setting the bridge priority to 8192 was not sufficient to make this switch the root. So, the priority was further reduced to 7192 (100 less than the current root switch) to make this switch the root switch. However, reducing it to this value did not make it the root switch for active VLANs 16 and 17.

Console> (enable) set spantree root 11-20.

VLANs 11-20 bridge priority set to 7192
VLANs 11-10 bridge max aging time set to 20 seconds.
VLANs 1-10 bridge hello time set to 2 seconds.
VLANs 1-10 bridge forward delay set to 13 seconds.
Switch is now the root switch for active VLANs 11-15,18-20.
Switch could not become root switch for active VLAN 16-17.
Console> (enable)

Console> (enable) set spantree root secondary 22,24 dia 5 hello 1

VLANs 22,24 bridge priority set to 16384.
VLANs 22,24 bridge max aging time set to 10 seconds.
VLANs 22,24 bridge hello time set to 1 second.
VLANs 22,24 bridge forward delay set to 7 seconds.
Console> (enable) 

 


Misconceptions:

If you do not specify a VLAN number, VLAN 1 is used.

This command is not supported by the NAM.

This command runs on backbone or distribution switches.

This command increases path costs to a value greater than 3000.

If you enable MISTP, you cannot set the VLAN root. If you enable PVST+, you cannot set the instance root.

You can run the secondary root many times to create backup switches for use in case of a root failure.

The set spantree root secondary bridge priority value is 16,384 except when MAC reduction or MISTP are enabled, then the value is 28,672.

The set spantree root bridge priority value is 16,384 except when MAC reduction or MISTP are enabled, then the value is 24,576.


Related Commands:
show spantree

� Cisco Systems, Inc. 2001, 2002, 2003
World Wide Education

Converted from CHM to HTML with chm2web Pro 2.85 (unicode)