Powered by Blogger.
Showing posts with label STP advance. Show all posts
Showing posts with label STP advance. Show all posts

CCNA Advance- STP (Spanning Tree Protocol) : Part 3

BackboneFast:


In order to detect indirect link failure and to optimize network convergence time, Backbone Fast feature of STP is used. Backbone fast (BF, in short) is a CISCO proprietary feature. The term indirect link failure needs a little explanation. The link which is not directly connected to the core switch and which fails, such a link failure is called indirect failure. This indirect link failure is detected by a switch when it receives Inferior BPDUs! In order to understand Inferior and Superior BPDUs, we take following scenario:


Please note: f1/1 is in BLK and f1/2 is in FWD state

Suppose normal STP is running in our above topology. SW2 has been elected as our root bridge, BPDUs are continuously sent from SW2 to SW1 and SW3 every 2 seconds that SW2 has the lowest Bridge ID and it’s the root Bridge. SW1 has second lowest bridge ID. 



Now just imagine that the link between SW1 and SW2 goes down. As SW1 has second lowest bridge ID, and is now disconnected from SW2, it will proclaim itself as the root Bridge and will begin to advertise the same in its BPDUs, sending BPDUs to SW3, telling SW3 that it has the lowest bridge ID and it’s the root! At the same time SW3 is also receiving BPDUs from SW2, SW2 claims in its BPDUs to be the lowest in priority and the ultimate root bridge J Now to clear this confusion, SW3 compares both (SW1 and SW2) BPDUs, and it quickly realizes that BPDUs from SW1 are Inferior BPDUs and simply discards it. It only seriously considers the Superior BPDUs from SW2 only! Once Maxage Timer Expires on f1/1 port on SW3, it transitions into listening and after a certain time it begins to relay Superior BPDU data to SW1.










Now what role will backbonefast play, if it enables on all these switches? Backbonefast will minimize this Maxage timer interval. By enabling Backbone fast this Maxage stage is skipped, the delay is minimized from 50 seconds to 30 seconds! It sounds not a big deal but in a live network, such delay minimization at core switches greatly optimizes network performance.  All this magic is done by using Root Link Query protocol by switch once Backbonefast is enabled. Please remember one important thing, Backbonefast is always enabled on core switches, and to make all switches in a topology understand RLQ protocol, Backbonefast must be enabled on all switches in that topology!

The configuration of Backbonefast is quite simple. Its enabled globally by going into global configuration mode. The command to verify and configure Backbonefast is as follow:





Root Guard:

As the name suggests, in order to prevent entry of any new root switch into the network, Root Guard feature of STP is enabled on the interface to which new switch is going to be connected. Once Root Guard is enabled on an interface, it will discard all the superior BPDUs coming into that port and will change the port into Root-Inconsistent state; it will also discard Superior BPDUs until it stops receiving it.

Suppose in our above network topology we are going to connect a new switch to SW3 fa0/24. The Root Guard will be enabled as following on SW3 fa0/24:





If our new switch will send any Superior BPDU towards fast 0/24 of SW3, it will be discarded and port changed into Root-Inconsistent state until it stops such packets!


BPDU Guard:

In order to protect our network from loops, BPDU guard is configured on all ports on which Portfast is enabled. Because it’s expected that we can accidently plug any switch into our portfast enabled interface and can totally ruin our network by creating loops. Once BPDU Guard is enabled on an interface, it will discard any BPDU received and will instantly shutdown and will put the interface into err-disabled state.

To configure BPDU Guard on a specific interface, say SW1 fast 0/5 we use following commands:





To configure it on all ports, which by default must be running on portfast:




CCNA Advance- STP (Spanning Tree Protocol) : Part 2

STP- Enhancements



PortFast:

As for now we are well equipped with STP, now we turn to STP optimization techniques. STP optimization is necessary for fast convergence times in the network, as the standard 4 step convergence of STP can cause a lot of havoc in the real time network. In this article we would like to discuss STP: Port fast, Uplink fast, and Backbone fast.

When a switch powers up or when some device is connected to a switch, STP immediately comes into action. In the initial phase the port enters into a spanning tree listening state. Listening state is just like a network topology exploration, this state lasts for a certain time, and then the port transitioned into a learning state. After an STP forward timer threshold the port state changes into either blocking mode or forwarding mode. In a real time network, most of the time we can’t afford the switch port to transition through all these 4 stages. We want the port to immediately shift into a forwarding state, once a network is alive, to avoid un-necessary packet delays in the network.  For this purpose we use an STP PortFast feature. Once PortFast is enabled on a switch/trunk port, the port skips the listening and learning phases and immediately shifts into the forwarding state. So one important point we need to remember is:

Only enable PortFast on End Stations, because it can create network loops if used carelessly (as it turns the port into a forwarding state immediately)!



So it was easy? Yes it was, now we move towards a new strange concept UpLink Fast.

UpLinkFast:

By using UpLink fast on a port, fast convergence is achieved via creating UpLink Groups. Once a topology change occurs, convergence is achieved using these UpLink groups, which activate the redundant links (ports) instantly. This redundancy is achieved without hassle of passing the redundant link through all STP transition phases (i.e. listening, learning), within 1-5 seconds:  redundant link (port) is in forwarding state. An UpLink group consists of the root port and set of blocked ports. This UpLink group consists of alternate path if the active root port fails. Some of the worth remembering points regarding UpLink fast are:


  • It cannot be configured on a root switch.
  • When UF is enabled, it’s enabled globally and for all VLANs residing on the switch.
  • The designated port (root port) will retain its status once it detects that the failed link has been restored and fully operational.
  • The wait interval for the port to become root port again is determined by: (2 x FwdDelay) + 5 seconds.
  • UF will take immediate action to prevent the switch (on which UF is enabled) from becoming the root switch by: changing the switch priority to 49,152, making it the last option in a network topology for becoming a root switch. The STP port cost is increased up to 3000 making it least feasible part for any switch to use it to reach the root switch. 


I think that much theory is enough, now we will do some configurations to solidify our concepts. For our example scenario we are using GNS3 and emulating C2961 router as a switch because packet tracer is not giving us much options to implement advance STP.






For complete article, please download it from below mentioned link and Enjoy:

http://www.mediafire.com/download/r69bzogi3g3lid8/STP-Enhancements_Part_1.pdf