Tag Archives: SWITCH 300-115 1.6a

SWTCH 300-115 1.6 Configure and verify spanning tree

1.6.a PVST+, RPVST+, MST

We understand that the sys-id-ext field in spanning-tree is represented by 12 bits of the total 2 byte priority field. The other 4 bits represent the priority in multiples of 4096. We also understand that 2 to the 12th gives us 4096 possible vlans (0-4095 is 4096 vlaues total, 4094 of which are actually configurable), and the determined vlan (if not the default Vlan 1) plus the priority (if adminstratively configured other than the default 32768) completes the priority calculation:

SW2#sh spann | i Br
Bridge ID  Priority    32769  (priority 32768 sys-id-ext 1)

We have 4 bits for priority. gmail sign in guide 4 bits gives us only 16 possible priority values. (2 to the 4th, feel free to do the binary)

65536/16=4096

This is also why the root primary/secondary macro is decremented by 4096; there is no choice.

SW2(config)#spann vlan 1 prio 32767
% Bridge Priority must be in increments of 4096.
% Allowed values are:
0     4096  8192  12288 16384 20480 24576 28672
32768 36864 40960 45056 49152 53248 57344 61440

 

sys-id-ext

SWITCH 300-115 1.6 Configure and verify spanning tree

1.6.a PVST+, RPVST+, MST

STP

In order to facilitate a loop free topology a root switch is elected as a reference point for the entire tree. This is accomplished by establishing a BID (bridge id) for every switch in the diameter. A bridge ID is an 8 byte construct composed of 2 bytes of priority, and 6 bytes MAC address. Further, the priority is segmented into 4 bits priority and 12 bits extended system id, where the extended system id is the VLAN ID.

VLAN0010

Spanning tree enabled protocol rstp

Root ID Priority 32778

Address 0009.b73f.ce80

Cost 12

Port 64 (Port-channel2)

Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 32778 (priority 32768 sys-id-ext 10)

32768 16384 8192 4096 2048 1024 512 256 128 64 32 16 8 4 2 1

here is the binary math with the example vlan 10

1000 0000 0000 1010

32768 + 8 + 2

 

SWITCH 300-115 1.6 Configure and verify spanning tree

1.6.a PVST+, RPVST+, MST

common spanning tree

the original iteration of  802.1q defined a single instance of spanning tree regardless of the amount of vlans; a common tree for the entire network.  when a path is blocked due to convergence, as it will be, there is but one path for the vlans to traverse toward their destination.

this is hardly fair for the multiple vlans that could potentially take more than one path if given the opportunity.

so the common tree does not allow for load balancing although this is ultimately less cpu intensive.

enter mst

by definition mst supports multiple trees similar to pvst, which supports an instance per vlan.  however, unlike pvst, a reduction in the total amount of instances can be achieved by balancing, grouping, vlans together and shipping them across different paths; many vlans;

1.6 Configure and verify spanning tree

1.6.a PVST+, RPVST+, MST

after initializing, a switchport always enters the blocking state

blocking:
the port dumps the frames received
dumps frames switched for forwarding from another switch
doesn’t learn shit
receives bpdu’s

listening:

the port dumps the frames received
dumps frames switched for forwarding from another switch
doesn’t learn shit
receives bpdu’s

learning:
the port dumps the frames received
dumps frames switched for forwarding from another switch
finally gets off its dead ass and learns addresses
receives bpdu’s

forwarding:
receives and forwards frames
forwards frames switched from another port
learns addresses
receives bpdu’s

disabled: guess

 

 

SWITCH 300-115 1.6 Configure and verify spanning tree

1.6.a PVST+, RPVST+, MST

STP elects a root bridge (switch) and puts all root bridge interfaces into forwarding state
Each non root bridge (switch) determines which of its ports has the least administrative cost (best) to the root bridge and STP makes that port that switch’s root port.
The switch with the lowest (best) cost  to the root is put in forwarding state.
The lowest cost switch on each segment is the designated bridge (switch) and the interface on that switch is called the designated port.
            The root bridge’s (switch) ports are always in forwarding state and the root switch (bridge) is always the designated bridge on all connected segments.
            The non root bridge root port is always forwarding. This port receives the lowest cost BPDU from the root.
            Each LAN’s designated port is always forwarding and the bridge forwarding the lowest cost BPDU is the segment’s designated bridge (switch)
             All other ports are blocking. No forwarding frames, no receiving frames.
         At first each switch claims to be root by sending BPDU’s that contain:
                 The root bridge ID- a combination switch priority and MAC address, lower number, higher priority
             The cost to reach the root- again the lower, the better

And it’s own bridge ID