Showing posts with label Cisco STP. Show all posts
Showing posts with label Cisco STP. Show all posts

Tuesday, 18 January 2011

Spanning Tree Protocol

Hi some key points I would like to share with you on STP

PortFast:

setup Layer 2 LAN interface of the switch as an access port to enter the forwarding state immediately, bypassing the listening and learning states. Use PortFast only when connecting a single end station to a Layer 2 access port.


UplinkFast:

Provides from three to five seconds convergence after a direct link failure and achieves load balancing between redundant Layer 2 links using uplink groups.


BackboneFast:

Cuts convergence time by max_age for indirect failure.

BackboneFast is initiated when a root port or blocked port on a network device receives inferior bridge protocol data units (BPDU) from its designated bridge.


Loop guard:

Prevents an alternate or root port from becoming designated in the absence of BPDUs. Loop guard helps prevent bridging loops that could occur because of a unidirectional link failure on a point-to-point link.

Root guard:

Secures the root on a specific switch by preventing external switches from becoming roots.

BPDU guard:

When configured on a PortFast-enabled port, BPDU guard shuts down the port that receives a BPDU.

Unidirectional Link Detection (UDLD):

UDLD monitors the physical configuration of fiber-optic and copper connections and detects when a one-way connection exists. When a unidirectional link is detected, the interface is shut down and the system alerted.

Friday, 13 February 2009

Spanning tree Protocol




SPANNING TREE



Spanning tree protocol is Layer 2 protocol that ensures the loop free topology, it is based in angorithum invented by Radia Perlam.


Some of the main Points to cram about STP are as under (soon i will add some Cisco related troubleshooting commands and PVST stuff............)



  • STP 802.1d was created to prevent loops in the network, and it is Industry standard protocol.

  • All the switches running STP use to send Probes into the network, which are known as “BRIDGE PROTOCOL DATA UNIT” (BPDUS) to discover loops, however these BPDUs also help to elect the ROOT BRIDGE, which is the core switch in the network.

  • In redundant network running STP switches find the best path to reach the root bridge elected, and then block rest of the redundant links.

  • BPDU packets are sent every 2 seconds , from every active ports of switch to detect the redundancy and link failure , this BPDU packet contains 2 major fields Mac Address and Priority , Which helps to elect the root Bridge

  • Priority field in BPDU can contain value from 0 to 61440 , but the default value is 32768 and lower is better

In order to break a tie between switches having default priority value i.e 32768 , is the point where MAC address kicks in , and lower the MAC address the higher the priority , if lower the MAC address then older the switch will be ............. (hope not got confused ;) ... so we cannot make older switch the root bridge ... so we need to configure root bridge with smaller priority value so the election will be on the basis of Priority not MAC address .


Three Port types in STP

Root Port : this is used reach the root bridge .... remember Root bridge don’t have any root port


Designated port : forwarding port but other end should be locked


Blocking/ Non Designated Port: its the blocked port by STP


STP find the best path by selecting the cost of links i.e cost of 100 Mbps is 19 if link cost ties then bridge id will break the tie

Bridge ID = Priority + Mac address

Per VLAN Spanning Tree

All modern Cisco Switches Run PVST , which runs one instance of Spanning tree per vlan

One root bridge for each VLAN which helps to load balance more effectively