Header Ads

  • Breaking News

    Good news ! Good news !! Good news !!! soon you all will be able to download important software in our download section...

    STP

    The Spanning Tree Protocol (STP) is a network protocol that builds a loop-free logical topology for Ethernet networks. The basic function of STP is to prevent bridge loops and the broadcast radiation that results from them. Spanning tree also allows a network design to include backup links to provide fault tolerance if an active link fails.

    Protocol Operation:

    The need for the Spanning Tree Protocol (STP) arose because switches in local area networks (LANs) were often interconnected using redundant links to improve resilience should one connection, called a link, fail. However, this was found to create transmission loops, broadcast storms and MAC address table trashing. If redundant links are used to connect switches, then transmission loops need to be avoidedbecause data link layer 2 Ethernet frames do not expire. Potentially an Ethernet frame with a destination MAC address that is not in the MAC address table of the immediate switch can be bounced around between switches in the local area network. Redundant links between these switches could result in the Ethernet frame never reaching a Switch that has the destination MAC address in its MAC address table. In such cases switches also broadcast the Ethernet frames to all ports, except the one from which it entered. This can create a broadcast storm. However, if only one link between switches exists, entire segments of the local area network would become unavailable should this one link fail. Thus it has become best practice to establish a second redundant link between critical switches.[5] If more than one link between two switches are used to transmit Ethernet frames, a switch will receive Ethernet frames with the same source MAC address through two ports, resulting in what is known as MAC address table trashing.
    To avoid the problems associated with redundant links in a switched LAN the Spanning Tree Protocol (STP) is implemented on switches to monitor the network topology. Every link between switches, and in particular redundant links, are catalogued. STP then disables redundant links by setting up one preferred and optimized link between switches in the LAN. This preferred link is used for all Ethernet frames unless it fails, in which case the non-preferred redundant link is enabled. When implemented in a network, STP designates one layer 2 switch as root bridge. On this root bridge the preferred and non-preferred links are calculated. The root bridge switch constantly communicates with the other switches in the LAN that implement STP, called non-root bridges, using Bridge Protocol Data Units(BPDUs).

    Provided there is more than one link between two switches, the STP root bridge calculates the cost of each path based on bandwidth. STP will select the path with the lowest cost, that is the highest bandwidth, as the preferred link. STP will enable this preferred link as the only path to be used for Ethernet frames between the two switches, and disable all other possible links by designating the switch ports that connect the preferred path as root port.The STP path cost default was originally calculated by the formula 1 Gigabit / second/bandwidth. When faster speeds became available, the default values were adjusted as otherwise speeds above 1 Gbit/s would have been indistinguishable by STP. Its successor RSTP uses a similar formula with a larger numerator: 20 Terabit / second/bandwidth. These formulas lead to the sample values in the table on the right.
    After STP enabled switches in a LAN have elected the root bridge, all non-root bridges assign one of their ports as root port. This is either the port that connects the switch to the root bridge, or if there are several paths, the port with the preferred path as calculated by the root bridge. Because not all switches are directly connected to the root bridge they communicate amongst each other using STP Bridge Protocol Data Units (BPDUs). Each switch adds the cost of its own path to the cost received from the neighboring switches to determine the total cost of a given path to the root bridge. Once the cost of all possible paths to the root bridge have been added up, each switch assigns a port as root port which connects to the path with the lowest cost, or highest bandwidth, that will eventually lead to the root bridge

    STP Switch Port States:


    • Blocking - A port that would cause a switching loop if it were active. No user data is sent or received over a blocking port, but it may go into forwarding mode if the other links in use fail and the spanning tree algorithm determines the port may transition to the forwarding state. BPDU data is still received in blocking state. Prevents the use of looped paths.
    • Listening - The switch processes BPDUs and awaits possible new information that would cause it to return to the blocking state. It does not populate the MAC address table and it does not forward frames.
    • Learning - While the port does not yet forward frames it does learn source addresses from frames received and adds them to the filtering database (switching database). It populates the MAC address table, but does not forward frames.
    • Forwarding - A port receiving and sending data in Ethernet frames, normal operation. The Forwarding port monitors incoming BPDUs that would indicate it should return to the blocking state to prevent a loop.
    • Disabled - A network administrator has manually disabled a switch port

    Post Top Ad

    image name

    Post Bottom Ad

    imagename