HOME  |    TRAINING  |   FREE TUTORIALS   |   JOBS
Find out more about our new RSS feed.
FREE Tutorial
SPANNING TREE PROTOCOL (STP)

CATEGORY
SEARCH OUR OTHER TUTORIALS

DESCRIPTION

Layer 2 LAN protocols have no method to stop traffic endlessly travelling around possibly carrying inaccurate information. At layer 3 we can make packets die after a certain amount of time or after they have travelled a certain distance. It quickly became evident that a system to prevent loops was needed if LANs were to continue to function.


TUTORIAL TAKEN FROM COURSE : CCNA MODULE 3 - LAN SWITCHING

FULL COURSE DETAILS

At the end of all the modules within this course you will be able to – understand LAN and WAN networking concepts. You will understand TCP/IP and IP addressing and subnetting. You will understand the routing process and be able to configure a Cisco router and switch for use in a live network environment.

TO ACCESS THE FULL COURSE AND HUNDREDS OF OTHERS, CLICK HERE.


"Pass your IT exams by learning with our world class consultant trainers. Your hands on course comes with a 100% satisfaction money back guarantee and lifetime e-mail support to give you the very best chances of passing." This tutorial has been written and prepared by http://www.networksinc.co.uk

Spanning Tree Protocol was developed as a method of loop prevention on LANs. It allows bridges to communicate with each other so they can create a loop free topology. Each bridge runs an algorithm which calculates how the loop can be prevented.

STP has only one purpose, to prevent loops occurring on a network by blocking connections that could cause a loop. When a port sees a loop in the network it blocks one or more redundant paths preventing a loop forming. This is achieved by STP electing a root bridge on the network. Then each other bridge selects one of its ports with the least path cost to the root bridge. The least cost path is determined by STP looking at the bandwidth of the link.

STP continually monitors the network always looking for failures on switch ports or changes in the network topology. If a change is notices STP can quickly make redundant ports available and close other ports to ensure the network continues to function.

How are loops caused? Very easily, LANs are designed to provide redundancy so that if a particular link fails another one can take over passing the frame across the LAN. Each switch port on a LAN hears a hosts MAC address and sends a message around the network telling the other switches that it knows how to get to host X.


FIG 3.4 A Switching Loop is Easily Caused

The problem starts when another switch discovers hosts X’s MAC address. As time passes every switch on the network thinks it knows how to get to PC X and a loop has formed. A loop can very quickly bring down your network.

Spanning tree works by selecting a root bridge on the LAN. The root bridge can be though of the centre of a web. It is selected by comparing each others MAC address and priority value. The default priority value of on all devices running STP is 32768.

When the root bridge is selected the other switches then the other switches elect a port with the least path cost to use on the LAN.

The root bridge on a LAN is selected by an election taking place. Each switch running STP passes information in a format called bridge protocol data units (BPDUs). When the switch or bridge priorities combined with its MAC address are all exchanged the bridge with the highest ID is selected as the root bridge.

All ports on the root bridge are known as designated ports. On nonroot bridges only one port can be designated, all others are blocked. Designated ports forward MAC addresses. Designated ports are selected after the bridge determines the lowest cost path to get to the root bridge.

Root bridge ports are known as designated ports and are in what is known as forwarding state. Forwarding state ports can send and receive traffic. All of the other bridges present are known as nonroute bridges, they choose a port known as a root port which sends and receives traffic.

By using this method, the redundant links are closed down. They can be opened again if there is a change in network topology and the link is needed once more.

Bridge ports running STP can be in one of four states:

  • Listening - listens to make sure no loops occur before passing frames
  • Learning - learns MAC addresses but does not forward frames
  • Blocking - listens but will not forward frames
  • Forwarding - sends and receives frames on the port

STP in operation

In our network we can now see which segments are Ethernet and fast Ethernet.


FIG 3.5 STP Chooses Closes Down the Redundant Links

This time Switch A (nonroot bridge) advertises the fact it can get to PCX to Switch B. Switch A will only take one path to get there since port 1 is blocked. It is blocked since it is a slower link than port 0 which is on a fast Ethernet segment of the LAN.

Bridging is the same thing as switching despite what you have heard in other books. They do exactly the same job however they are different types of device. A bridge is generally a software based device and can only run one spanning tree instance per bridge. Also, there are normally only up to 16 ports per bridge.

LAN switches are hardware based, the have a special chip used to store the MAC addresses known as an application specific integrated circuit (ASIC). Switches support multiple instance of spanning tree per switch and they also can have more than 16 ports (more than 100 on some models).

Spanning tree is turned on by default on Cisco switches.




8 RELATED COURSES AVAILABLE
CCNA MODULE 1 - INTRODUCTION TO INTERNETWORKING
At the end of all the modules within this course you will be able to – understand LAN and WAN networking concepts....
CCNA MODULE 2 - CONNECTING AND CONFIGURING CISCO DEVICES
At the end of all the modules within this course you will be able to – understand LAN and WAN networking concepts....
CCNA MODULE 3 - LAN SWITCHING
At the end of all the modules within this course you will be able to – understand LAN and WAN networking concepts....
CCNA MODULE 4 - IP ADDRESSING
At the end of all the modules within this course you will be able to – understand LAN and WAN networking concepts....
CCNA MODULE 5 - ROUTING PROTOCOLS
At the end of all the modules within this course you will be able to – understand LAN and WAN networking concepts....
 
1 RELATED JOBS AVAILABLE
SUPPORT SERVICES ENGINEER
<P>Support services Engineer</P><P>My client is looking for an experienced IT Maintenance....
CONTACT US
Wednesday 3rd December 2008  © COPYRIGHT 2008 - VISUALSOFT