Classic "Cisco Lan Switching" chapter sixth (v): Three Steps of Initial STP Convergence

Source: Internet
Author: User
Tags switches

"Copyright notice: Original translation articles, translation level is limited, errors are unavoidable, The Translator is not responsible for the consequences of errors or omissions in the article, please be careful to reprint them. Reproduced please retain this statement and source: blog.csdn.net/shallnet, download the English version of the book "


This section describes the initialization convergence of spanning tree protocol on a logical, non-ring topology, although spanning tree protocol initialization convergence involves many aspects, but can also be decomposed into the following three simple steps:
    1. Select the root bridge
    2. Select the root port
    3. Select the specified port
When the network starts for the first time, all bridges emit non-organized BPDU information, and the bridge will immediately begin executing the four-step comparison principle described in the previous section, eventually forming the only tree on the entire network. The root bridge is selected as the only center of the network (the first step), all remaining bridges select the root port (second step) and the specified port (the third step) has established a loop-free topology map. You can think of this topology diagram as a wheel, the root bridge is the axis, the active non-ring path (vehicle spokes) outward radiation.       On a network with stable network conditions, only the root bridge sends BPDUs outward on the network. When the above three steps are completed, the network converges on the loop-free topology, and the other topology changes are handled by the topology Change program, which is described in the section "Topology Changes Process".
To discuss the following chapters, we provide a network of three bridge/switch layouts as a discussion template in 6-6.Figure 6-6. Model Network Layout for Discussion of Basic STP Operations
The network consists of three bridges that are connected to the ring, each specifying a MAC address corresponding to its device name (for example, cat-a using MAC address Aa-aa-aa-aa-aa-aa).
First step: Select the root bridgeAll switches need to select a unique root bridge by looking for the minimum bridge ID (BID). Remember, in "STP economics", the smallest bid wins!        The process of choosing the minimum bid bridge is often accompanied by an exciting title named "Root Wars" < translator note: Root war>. Tip: Many documents discuss the use of the term "highest priority" in wartime, while the bridge has the highest priority and does have a minimum value, in order to avoid confusion, this article station always refers to "value" to describe the related problem.
As with the bridge ID discussed earlier, a bid is a 8-byte identifier consisting of a bridge priority and a MAC address, and from figure 6-6 you can see that Cat-a has a bid with a default value of 32768.AA-AA-AA-AA-AA-AA. Note that here the decimal and 16 binary are mixed, although this may seem odd, but this expression allows you to clearly see each part of the bid format. Remember: The minimum bid wins!
Similarly, Cat-b assumes that its default bid is 32768.bb-bb-bb-bb-bb-bb,cat-c is 32768.cc-cc-cc-cc-cc-cc. Because all bridges use the same default priority of 32768, the smallest MAC address, Aa-aa-aa-aa-aa-aa, defeats the other bridges at the same priority level, and cat-a is called the root bridge. This processFigure 6-7 is analyzed in the legend as follows:Figure 6-7. The Network must Select a single Root Bridge
So how did the bridge discover that Cat-a has the smallest bid? is actually done by exchanging bpdus. As mentioned before, BPDUs are a special kind of packet that is used between each bridge to exchange topology and spanning tree information, and the BPDUs are sent every 2 seconds by default. BPDUs are communication data channels between bridges and bridges, and they do not involve end-user information (such as Doom or e-mail). Figure 6-8 illustrates the basic structure layout of BPDUs (bpud format is described in detail in the "Types of BPDUs" section)Figure 6-8. Basic BPDUs Layout
Because this is the root bridge, it is only concerned with root bid and the sender's bid field (the real name is given later).       The bridge generates a BPDU every 2 seconds, where Root bid is the root bridge that he currently thinks is the Bid,sender bid domain of his own bid.                Tip: Remember that root bid is the bridge ID of the current root bridge, but sender bid is the bridge ID of the local bridge or switch. For example, a bridge is like a human being, a world that has just come to life revolves around you, in other words, when a bridge starts for the first time, the root bid and sender bid fields of bpud are filled in with their own bid. Suppose Cat-b first starts, sends bpud every 2 seconds and accompanies claims to be the root bridge. A few minutes later, Cat-c started and boasted that it was the root bridge, when Cat-c's BPDUs were sent to Cat-b,cat-b to drop the BPDU because there was a smaller bid on the Cat-b's port (cat-b own Bid). Once the cat-b sends the BPDU,CAT-C received after the discovery he assumed himself as the root bridge is incorrect, this time, Cat-c sent BPDUs to cat-b bid as root bid,cat-c bid for sender bid, This gives Cat-b an agreement on the root bridge in the network.Step Two: Select the root portThis is the work after the brutal root war, and the switch then starts to select the root port. The closest port to the root bridge is the root port of the network Bridge.each non-root bridge must have a root port selected.         As mentioned before, the bridge uses the concept of overhead to determine the distance, and the bridge records the so-calledRoot Path overhead, whose value is the cumulative overhead of each link to the root bridge. Figure 6-9 illustrates how this value is computed and the root port selection process through multiple bridges.Figure 6-9. Every non-root Bridge must Select one Root Port
When Cat-a (Root bridge) sends BPDUs, it contains a root Path cost of 0 (the first step). When the Cat-b receives the frame, its connection to the received BPDU contains the root path cost plus the path overhead of Port 1/1. Assuming that the current network is using the Catalyst 5000 platform switch and the version is greater than 2.4, then all three links in Figure 6-9 are Fast Ethernet, so the cat-b receives the root Path cost with a value of 0 plusthe cost value for Port 1/1 is 19 (second step). Cat-b then sends a BPDU with root Path cost of 19 (step three) from Port . when Cat-c receives BPDUs sent from Cat-b (fourth step), it increases the value of root Path cost to 38 (19+19). However, Cat-c also received a bpud from the root bridge on Port 1/1 , whose path cost value is 0,cat-c increase that value to 19 (fifth step). This time cat-c needs to make a decision: a root port must be selected, and the port is closest to the root bridge. Cat-c found that the root path cost on port 1/1 was38, so port 1/1 became the root port (sixth step). Cat-c then began to tell its downstream switch that its root Path cost was 19. Although not described in detail in Figure 6-9, Cat-b also does a series of similar calculations: Cat-b on Port 1/1 to the root bridge overhead,port 1/2 overhead is 38, so port 1/1 becomes the root port of Cat-b. It is important to note that the overhead is incremented on the port that receives the BPDU. Tips:Remember that the overhead of STP is increased when the port receives BPDUs, not when it is sent out. For example, BPDUs reach Cat-b.The cost for Port 1/1 is 0 and then increased to 19 within the cat-b. This is discussed in more detail in the "Mastering the show Spantree Command" section.
Tips:
< Span style= "line-height:1.5" >
The
path cost is a value assigned to each port that is added when BPDUs are received on the port to calculate the root path overhead. The root path overhead is the cumulative overhead of the bridge to the Root bridge. In a BPDU transmission, the value of the Root Path cost domain is the value. In a bridge, this value is obtained by accumulating the path cost value of all ports that receive bpdus to the root path in BPDUs.
        Step Three: Select the specified portThe STP loop avoids part of the work that naturally falls into the third step of STP initialization convergence: Select the specified port. Each segment of the bridge network must have a specified port, which is the only bridge port that sends incoming traffic as the link and Root bridge, meaning that if there is only one port at all link traffic, then the loop is no longer possible.        The bridge that contains the specified port on this link is the designated bridge for this link. As with selecting the root port, the selection of the specified port is also based on the cumulative path cost value to the root bridge, root path costs (such as 6-10).Figure 6-10. Every Segment elects one designated Port Based on the Lowest cost
In order to find the specified port, each segment of the link needs to be checked sequentially. First check the first link, the section between Cat-a and Cat-b, which has 2 bridge ports: Cat-a PORT1/1 and Cat-bThe root path cost of the Port1/1,cat-a PORT1/1 is 0 (who makes it a root bridge), while the root path cost of the Cat-b PORT1/1 is 19 (the value is from Cat-a sent over BPDUs 0 plus cat-b PORT1/1 Path cost 19), because Cat-a:PORT1/1 has a smaller root path overhead, it becomes the specified port for this link.         Now look at the second link (cat-a to cat-c) and do a similar action. Cat-a:PORT1/1 root path overhead is 0, while Cat-c:PORT1/1 root path overhead is 19,cat-a: PORT1/1 has a smaller root path overhead to become the specified port. concluded: Each active port on the root bridge is the specified port the next third link (cat-b to cat-c): Cat-b:port1/2 and cat-c:port1/2 has a root path cost of 19. The same value! When encountering the same root path overhead (or the same as other values), STP always uses the previous "Four-step STP decision Sequence." This section discusses the four-step comparison principle, recalling that the four-step comparison principle is as follows:
    1. Minimum root bridge bid
    2. Minimum root path overhead
    3. Minimum sender bid
    4. Minimum Port ID
In example 6-10, all bridges agree that Cat-a is the root bridge, so go to the next step to calculate the root path overhead, as previously said, the root path cost for both Cat-b and Cat-c is 19, so proceed to the next comparison bid. Since Cat-b's bid for 32768.BB-BB-BB-BB-BB-BB is smaller than Cat-c's bid32768.cc-cc-cc-cc-cc-cc, all cat-b:PORT1/2 becomes the specified port on the third link, and cat-c:port1/2 becomes a non-specified port.
Review of STP initializationBefore proceeding, let's review the three-step initialization convergence process we've just discussed in this section:
    1. Select a root bridge
    2. Select a root port on the non-root bridge
    3. Select a specified port on each link
The first step, the bridge network selects a unique root bridge; The second step is to select a unique root port for each non-root bridge, which is the most recent of the Reagan Bridge; The third step is to select a unique specified port for each segment of the link. For example, a network that contains 15 switches and 146 segments (each switch port belongs to a link only), and the number of each STP consists of table 6-2.Table 6-2. STP components in a Switch and 146 Segment Network

STP Component

number

Root bridge

1

root port

14

Specify port

146

Also, all options are based on the following four-step comparison principle:
    1. Minimum root bridge bid
    2. Minimum root path overhead
    3. Minimum sender bid
    4. Minimum Port ID
each BPDU received by each port is compared to other bpdus (including those sent out), and only the best (or better) BPDUs are saved, remembering that "optimal" is the least value (for example, the smallest bid becomes the root bridge, The minimum cost is used to select the root port and the specified port. The port will stop sending BPDUs when it discovers a better BPDU.

Classic "Cisco Lan Switching" chapter sixth (v): Three Steps of Initial STP Convergence

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.