BGP understanding to prevent Loops

Source: Internet
Author: User

The BGP protocol is a strategic Routing Protocol. Its complexity is not due to the complexity of routing algorithms. The most important thing is to use BGP to control the routing flow.

Any routing protocol must first solve the loop problem. OSPFISIS uses the SPF algorithm to solve the problem. The OSPF algorithm is novel and a Diffusion algorithm, therefore, BGP uses a lot of small means in the design to focus on designing diverse control attributes. IGRPRIP. It's hard to find them in China)

1.BGP is an important attribute inherent in BGP. In the ASPATH and BGP Route update process, add the passed self-developed domain AS) number to the update process. In this way, when BGP finds that its own AS is also in the update process, it can be considered that a loop has occurred.

2.EBGP can be considered in this way. In some scenarios, problems may occur.

For example, AS100 10.233.40.0/19 is updated to AS200. In AS200, the automatic summary attributes of both manual and BGP are summarized into 10.233.40.0/17 and uploaded to AS300, and then transmitted back to AS100, in AS100's view, the ASPATH of this route is (300,200) and is not in it !! This will lead to the formation of the loop.

The solution is to add the ASSET value so that the values are aggregated after route aggregation) and retain the attribute values of the original aspath to prevent routing loops.

This flag method can be used to transfer between AS without loops. The problem arises. What if it is in an? In IBGP, the conversion from the beginning to the end is performed in an AS, and ASPATH is not necessary. Therefore, IBGP does not add the ASPATH attribute in BGP. How can this problem be solved?

3.Developers think of a wonderful idea. If IBGP is only passed in the adjacent areas, it means one-to-one. For example, I know A and A know B, but I don't know B, because A won't introduce me to each other. If such a rule is stipulated in BGP, Routes learned by IBGP are not published to other IBGP joining groups, so they cannot prevent loops, because they cannot generate loops and are all a line.

This method is very good, but in this way, we need to establish an adjacent relationship between the Network's second and second.

4.At this time, we can consider this issue according to the OSPF concept. If we find a representative, we will not solve it, that is, DR + BDR. in order to indicate that hi-tech has a pull-up name: Route reflectors, that is, RR. In this way, you can logically change to a simple hub-spoke structure. In fact, this idea is to partially release the hidden rules described above in section 3rd. That is, a man-in-the-middle mechanism is created to enable the man-in-the-middle mechanism to introduce the customers it knows to other customers. In order to prevent loops, some fairness rules must be implemented for middlemen. The most important thing is that middlemen cannot change the information sent by customers, in this way, even if the loop information is passed back, you can find your own RID from the update. That's why LOOPBACK is configured. How important is that, in MPLS, the request must be/32-bit.) No loop can be found. Smart!

5.However, when there are a lot of routers in the RR area, there are also physical resources that are not supported. If you have a lot of wives, you won't be able to do much. Otherwise, people will be killed. So, how can we share it? Can we divide the data into several areas like OSPF, and keep necessary connections between different areas? Yes, I am the master of my program, so the BGP developers thought of it. By dividing an AS into several small AS S, the small AS s are connected by EBGP, using RR inside small AS is a great design. Laifeng's name is indispensable ---> confederation, I wonder why it's not called a tribe ?) AS is invisible to other. In this way, the structure is complicated. How can we simplify the structure more complicated ?).

How can we solve the inter-Alliance loop problem after the alliance was invented? In fact, this problem has been well solved. You must be smart enough to think about it. You can just make a shanzhai ASPATH. That's exactly the case. Correct the ASPATH attribute of BGP, it is not enough to make it take effect in the scenario of the alliance.

The formation of the loop is summarized here, and there is another unwritten rule, namely, BGP synchronization rules, which is also designed to prevent loops and routing black holes. The method to interrupt this rule is to establish a full adjacent structure for the entire network. I can write it directly for better understanding.
 

Edit recommendations]

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.