Re: STP root primary and secondary

From: Andy Reid <ccie_at_reid.it>
Date: Tue, 23 Mar 2010 00:14:51 +0800

Hi Jack,

I thought I would test this out on 2 x 3560 switches connected with one
trunk and sharing the same VTP domain and share my findings with you.
In conclusion, the priority value initially starts out with a value of
32768 on all switches and the highest MAC address is used to determine
the root bridge in the event of a priority tie. Entering the "root
primary" command will reduce the priority value to 24576. However, if
the switch priority has been manually reduced to either 4096, 8192,
12288, 16384 or 20480 then the same command will equal the priority
value unless it has a lower MAC address where it will reduce the
priority by 4096 to ensure it becomes the root bridge for that VLAN (the
switch with a lower MAC address knows it cannot win the tie if
priorities are equal).
Details below:

SW1 was initially the root after power up:
SW1#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 32769
             Address 001c.0f08.1300
             This bridge is the root
  Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)
             Address 001c.0f08.1300

SW2#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 32769
             Address 001c.0f08.1300
  Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)
             Address 001c.b0c4.5880

Entering the "spanning-tree vlan 1 root primary " command on SW2 moved
the root bridge for VLAN 1 onto SW2:
SW2#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 24577
             Address 001c.b0c4.5880
             This bridge is the root
  Bridge ID Priority 24577 (priority 24576 sys-id-ext 1)
             Address 001c.b0c4.5880

SW1#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 24577
             Address 001c.b0c4.5880
  Bridge ID Priority 32769 (priority 32768 sys-id-ext 1)
             Address 001c.0f08.1300

So far so good. Priority has changed to 24576 + 1 (for VLAN 1).

Now I thought, what if I entered the same command on SW1? it moved the
root bridge for VLAN 1 back to SW1 as both priorities are now the same
and SW1 has a higher MAC address so wins the tie:
SW1#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 24577
             Address 001c.0f08.1300
             This bridge is the root
  Bridge ID Priority 24577 (priority 24576 sys-id-ext 1)
             Address 001c.0f08.1300

SW2#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 24577
             Address 001c.0f08.1300
  Bridge ID Priority 24577 (priority 24576 sys-id-ext 1)
             Address 001c.b0c4.5880

Next I manually changed the priority on SW2 - "spanning-tree vlan 1
priority 20480" to be lower than 24576 and the root bridge for VLAN 1
moved back to SW2 as expected:
SW2#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 20481
             Address 001c.b0c4.5880
             This bridge is the root
  Bridge ID Priority 20481 (priority 20480 sys-id-ext 1)
             Address 001c.b0c4.5880

SW1#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 20481
             Address 001c.b0c4.5880
  Bridge ID Priority 24577 (priority 24576 sys-id-ext 1)
             Address 001c.0f08.1300

Then, entering the "spanning-tree vlan 1 root primary " command on SW1
moved the root bridge for VLAN 1 back onto SW1, the command matched the
existing root bridge priority, effectively configuring SW1 with a
priority of 20480 (SW1 has a higher MAC address):
SW1#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 20481
             Address 001c.0f08.1300
             This bridge is the root
  Bridge ID Priority 20481 (priority 20480 sys-id-ext 1)
             Address 001c.0f08.1300

SW2#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 20481
             Address 001c.0f08.1300
  Bridge ID Priority 20481 (priority 20480 sys-id-ext 1)
             Address 001c.b0c4.5880

Lastly, entering the "spanning-tree vlan 1 root primary " command on SW2
moved the root bridge for VLAN 1 back onto SW2, the command reduced the
existing root bridge priority by 4096, effectively configuring SW2 with
a priority of 16384:
SW2#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 16385
             Address 001c.b0c4.5880
             This bridge is the root
  Bridge ID Priority 16385 (priority 16384 sys-id-ext 1)
             Address 001c.b0c4.5880

SW1#show spanning-tree vlan 1
VLAN0001
  Root ID Priority 16385
             Address 001c.b0c4.5880
  Bridge ID Priority 20481 (priority 20480 sys-id-ext 1)
             Address 001c.0f08.1300

Best regards, Andy

Jack wrote:
> Thanks to all replies.
>
> Ladee Geek wrote:
>> I recall the old 2900 series used the 8192 and 16384. I'm not sure
>> when it changed, but I recall it being chagned to support dot1q.
>>
>>
>>
>> On Mon, Mar 22, 2010 at 10:33 AM, Jack <ccie.unnumbered_at_gmail.com
>> <mailto:ccie.unnumbered_at_gmail.com>> wrote:
>>
>>
>> http://www.cisco.com/en/US/products/hw/switches/ps708/products_configuration_example09186a00807b0670.shtml#PVST
>>
>>
>> In the article above, it says,
>> *Note: *The *spanning-tree root primary* command alters the
>> switch's bridge priority to *8192* and the *spanning-tree root
>> secondary* command alters the priority to *16384*.
>>
>> In my lab with Cisco 3560, it shows:
>> spanning-tree vlan 10-15 priority 24576
>> spanning-tree vlan 16-20 priority 28672
>>
>> after I entered the root pri and root sec commands, respectively.
>>
>>
>> Question:
>> 1. What is the date of the mentioned link?
>> 2. What versions will show 8192 and 16384?
>>
>>
>> My version is 12.2(44)SE2.
>>
>>
>> Thanks,
>> Jack
>>
>>
>> Blogs and organic groups at http://www.ccie.net
>> <http://www.ccie.net/>
>>
>>
>> _______________________________________________________________________
>> Subscription information may be found at:
>> http://www.groupstudy.com/list/CCIELab.html
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> --
>> r/
>> Tammy
>
>
> Blogs and organic groups at http://www.ccie.net
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html

Blogs and organic groups at http://www.ccie.net
Received on Tue Mar 23 2010 - 00:14:51 ART

This archive was generated by hypermail 2.2.0 : Thu Apr 01 2010 - 07:26:35 ART