Folks, on a given 3750 switch I do 'show vlan' and I see vlan 1,3,4 and 7.
spanning-tree mode is rapid-pvst.
Can you confirm if I do:
"#spanning-tree vlan 1,3,4,7 root primary"
is the right way to make this is the root brige. I am just wondering what happens if I assign a new vlan... then it means I would need to add to the spanning-tree vlan <> root command. This sounds strange.
There are 2 ways to assign root -
1) spanning-tree vlan 1,3,4,7 root primary
2) spanning-tree vlan 1,3,4,7 priority where priority value is usually 8192
I usually use the second option but there is no reason not to use the first. Be aware that option 1) does not recalculate if a switch with a lower priority is added eg.
if you run the 1) command and the priority is set to 16384 and then a switch is added with a priority of 8192 to the network then the switch with 8192 will be STP root for the relevant vlans.
With either 1) or 2) you need to add new vlans when they are created.