Tuesday, October 25, 2016

4 comments

inTroDucTion To Spanning Tree Protocol

In mid-1980’s, there is something called “Ethernet Bridges”.
                “A Bridge made Layer 2 forwarding decisions in Software, as supposed to Hardware as a Switch does". Bridges operates slower than Switches. They don’t have ASIC, they don’t have those Application Specific Integrated Circuit. Circuitry that’s dedicated to making these Layer2 forwarding decisions but the basic theory of operation of a bridge is the same as a Switch. A bridge like a Switch can take a look at the “Destination Mac-Address” on a “Ethernet Frame”, and make a forwarding decision, based on the Destination Mac-Address and that Bridge can learn, what Mac-Addresses reside of a different bridge ports and, like you see in Picture.            
                   We could have redundant links between these Ethernet Bridges, and today we do the same thing with Ethernet Switches, and by Redundant Links, means we could lose any of these 3 different links that you see, and there would still be a path from any Bridge to any other Bridge, but there is an issue with this design what we have on Picture is a “Layer 2 Topological Loop”, and with a “Layer 2 Topological Loop”, we could have some really ugly side effects, if all of these links were simultaneously forwarding traffic.
      For Example, we can have Ethernet frame that just endlessly circulated around and around to this topology, so there is argument that Redundancy is good thing, but a Layer2 Loop is a bad thing but
Ø  in end of mid 1980’s, Radia Perlman working at Digital Equipment Corporation develops Spanning Tree Protocol or STP
Ø  and a variant of that original STP implementation was made by the Standard
Ø   The IEEE, The Institute of Electrical and Electronics Engineers, and the 1990 they developed the Standard of IEEE 802.1D
                And as we get to our discussion of Spanning Tree Protocol, you gonna notice that we use the term “Bridge” a lot off, and the reason is “Radia Perlman” she worked with “Ethernet Bridges”. So the terminology sort of stuck, but just keep in mind when we use the term “Bridge” for example, we gonna be talking about a Root Bridge, realize that Bridge in today’s modern networks is going to be an “Ethernet Switch” but we still might use the term “Bridge” to referred to that Switch.
              A Layer 2 topological loop could cause us some issues, let’s take a look at some of those issues, if we do not have Spanning Tree Protocol running in our Networks.
             Let’s ask the question? Why would a Layer2 Topological Loop be bad for Layer2 but not bad for Layer3?
To illustrate, I have got couple of Layer 3 devices, couple of Routers on the Picture, and in the “Header” of Layer3 Packet, there is a “Field” called the “TTL” or the “Time-To-Live” Field.
                                “Every time a packet is routed by a router, it goes through a Router or HOP, that TTL value gets decremented, or it’s gets reduced by ONE (1)”, and if it reaches 0, it’s gonna be dropped, it’s not gonna be forwarded anymore. To illustrate let’s imagine that. This packet begins with the “Time-To-Live” value of 2.
When it goes to the Next Router, or HOP, it’s gonna be reduced to a TTL of 1.
               And when it goes into the Next Router, it’s gonna be reduced to a TTL of 0.
                And it’s no longer gonna be forwarded, it’s a very different story with a Layer2 Switch because “Ethernet Frame” do not have TTL value, and since there is no TTL field.
if we have a frame
That starts to go in loop like this.
                    It can Circulate Endlessly because there is nothing to cause to Time Out on the network. This can cause something called a “Broadcast Strom”.
                From one thing is, a devices that attached to a network that is experiencing a broadcast Strom, they can slow down and hang, because their NIC or Network Interface Cards are having to take time to examine each of these broadcast frames that coming. It can even lock up the mouse pointer, we not able to move the mouse around the screen.
That’s one reason that Layer2 Topological loop can be a very Negative thing. Let’s now take a deeper look at some of these Symptoms, which can result from a Layer2 topological loop.
     
Beginning with the Symptoms, which can cause the Switches Mac-Address Tables to become corrupted, where they have inaccurate information about where there is Mac-Address on the network lives.
Consider the example on Picture.
                   We got Switch A and Switch B, and let’s say that PC A is sending out a frame on this “Top Ethernet” segment.

                     And the frame on a common network segment is going to go, in this case to both Switch A and Switch B.
                      Both Switch A and Switch B will learn that the all AAAA.AAAA.AAAA’s Mac-Address. The Mac-Addresses, that we pretended belongs to PC A. The all AAAA.AAAA.AAAA’s Mac-Address lives on their Top Port, It lives on their Gigabit 1/0/1 Port  and that gets added to their Mac-Address Table also known as the CAM Table.
                               But here what we start to have an issue.
Each of these Switches is going to forward that frame.
                 Out of bottom segment and each switch is going to see the frame sent by the other switch, and PC B sees the same frame twice.
it’s now received a Duplicate frame.
                      And when Switch A and B see this frame on the bottom Segment, arriving from the other Switch, suddenly they see that here this frame appearing on the bottom port that’s looks like a, it came from the all AAAA.AAAA.AAAA’s Mac-Address and they think, Well we need to update our Mac-Address Table, and they will delete the entry.
                    Saying that “all AAAA.AAAA.AAAA’s Mac-Address lives on their gigabit 1/0/1 Port”, and they will  add an entry, saying “NO! that mac-address lives on the gigabit 1/0/2 port”. This means that our switches now have an incorrect information in the Mac-Address Table. The Mac-Address table another words has been corrupted on each of these Switches, and also we mentioned PC B received Duplicate frames, that’s one side effect having a Layer2 Topological Loop, and not having “Spanning Tree Protocol” to protect this from the loop.

Another issue we could have a “Broadcast Strom”, remember what Broadcast frame looks like that were, we have a Destination Mac-Address of all “FFFF.FFFF.FFFF” in Hexadecimal notation.
             We have all FFFF.FFFF.FFFF’s Mac-Address, and that Mac-Address is not going to be burned into some devices or Network Interface Card, and therefore that mac-address is not gonna be learned by a Switch.
 What does the Switch do? when it receives a frame, where the Destination Mac-Address is Unknown?
 “It’s not been learned by the Switches Mac-Address Table. Well it gonna flood that frame out of all over the Switchport’s, other than the port on which that frame was received”.

And in this example, PCA is sending out a broadcast frame
On that Top Segment.
Well, Switches A and B, they flood that out down to the Bottom Segment.
For PC B gets a couple of copies of that frames.
And the frame from Switch A goes into the Switch B.
And frame flooded out of the Switch B goes into the bottom Port of Switch A.
And Switches A and B, they flood those frames up to the Top Segment.
And now PC A getting a Duplicate copying of that Broadcast Frame, and this just to repeat itself. The Broadcast traffic continue to circulate around the networks.

     We have a Broadcast Storm. PC’s A and B, their being flooded with this Broadcast Traffic. These PC’s, there having the interrupt their normal operation to take a look at these frames coming in, and that’s preventing them from doing their normal duties. This can also dramatically increase the Processor Utilization.

Conclusion: -  Broadcast Storm can bring a network to its knees, but the good news is Spanning Tree Protocol can come to the rescue, and we gonna see how that works in our Next Topic.



             If You Like the Post. Don’t forget 
    to “Subscribe/Share/Comment”. Thank You.

4 comments:

  1. Really very great information for that post, am amazed and then more new information are get after refer that post. I like that post.

    CCNA Training in Chennai

    ReplyDelete
  2. I am happy to read your blog,its really informative and impressive content.keep updating..
    Best Electrical Project Center in Chennai | IEEE Electrical Projects in Velachery

    ReplyDelete