Hello everyone,
This post will introduce the BGP problem.
Topic
1. The EBGP neighbors of AR2 and AR4 are not established normally. Please analyze the reason and explain in detail.
2. There is an external route 10.1.1.1 on the AR1 device. How can the devices in the AS 200 access 10.1.1.1, preferably from the AR1-AR3 link? Please use multiple methods to complete the requirements.

The EBGP neighbors of AR2 and AR4 are not established normally. Please analyze the reason and explain in detail
Test the connectivity between the IP addresses used by AR2 and AR4 to establish a BGP peer relationship. Perform a ping test to check whether the IP addresses used by AR2 and AR4 to establish a BGP peer relationship are reachable. If the network layer is unreachable, troubleshoot the fault from the network layer to check the reachability of the interface IP address and route. If the network layer configuration is correct, check the link-layer fault, for example, whether the link-layer protocol is consistent. If the link is a PPP link, check whether PPP authentication is normal. After the link-layer fault is rectified, if the fault persists, the fault may be caused by the physical layer. Check whether the transmission line is faulty, the interface is faulty, the interface is shut down, the interface board is faulty, and the transmission device is faulty.
If the network layer can communicate normally, you need to enter the upper layer to analyze whether the BGP TCP port 179 is disabled in the transport layer. If not, the possible cause is in the BGP protocol. Check the configuration of the BGP protocol, such as:
a. Whether the BGP Router IDs of AR2 and AR4 conflict.
b. Whether AR2 and AR4 are configured with BGP authentication, the authentication information requirements must be consistent.
c. AR2 and AR4 are the established EBGP neighbor relationship, whether the configuration of its own AS number and neighboring AS number is correct.
d. If EBGP neighbors are established using non-directly connected addresses (for example: using loopback ports to establish), you need to check whether the loopback port address routes at both ends are reachable, check whether the neighbor configuration specifies EBGP TTL multi-hop and whether the update source address is correct Configuration.
e. Check whether peer ignore is configured, whether GTSM is enabled, and whether the address families at both ends match.
How can the devices in the AS 200 access 10.1.1.1, preferably from the AR1-AR3 link?
Use the Route-Policy tool of BGP to complete the requirements, and the routing requirements can be completed according to the BGP routing attributes.
If route selection is controlled on AR1 and AR2, AR3 and AR4 in AS200 preferentially select the link between AR1 and AR3. There are the following methods:
1. Use the AS-path attribute to control route selection. AS-path is a well-known mandatory attribute. The rule for route selection through AS-path is that the shorter the AS-path, the more preferred, that is, the smaller the number of ASs recorded in BGP routing, The better the route, so when AR1 sends 10.1.1.1 routes to AR3, the AS-PATH attribute is normally advertised. When AR2 sends routes to AR4, use Route-policy to add its own AS number 100 in front of the AS-path, (note that it is not recommended to add the AS of the number of the EBGP neighbor. It is not recommended to add other AS numbers to avoid the subsequent impact of the AS-PATH anti-loop mechanism on routing transmission). In principle, it is only necessary to ensure that the length of the AS-PATH transmitted from AR1 to AR3 is less than that transmitted from AR2 to AR4. The length of the AS-PATH can not only meet the routing requirements, but also can control the AS-PATH length when receiving 10.1.1.1 routes on AR3 and AR4, and can also realize the routing function.
2. Use the origin attribute to control route selection. Configure the origin attribute of the 10.1.1.1 route advertised to AR3 on AR1 as "i", and configure the origin attribute of 10.1.1.1 route advertised to AR4 on AR2 as "?", In the case of the same AS-PATH attributes, comparing the original attributes can also achieve priority access to 10.1.1.1 through the AR1-AR3 path, or when AR3 and AR4 receive 10.1.1.1 routes, the origin attribute value can be set to achieve routing requirements.
3. Use the MED attribute to control route selection. MED is an optional non-transitive attribute. When AR1 sends routes to AR3, configure MED to a smaller value by using route-policy or modify MED to a higher value when AR2 sends routes to AR4. A large value can affect the route selection of AS200 devices, and can also receive 10.1.1.1 routes in AR3 and AR4 to modify the MED attribute to achieve path control requirements.
4. Configure the local-preference of 10.1.1.1 routing on AR3 and AR4 to influence the AS200 device to prefer the AR1-AR3 link. Local-preference is a recognized arbitrary attribute. Route selection is based on local preference. The larger the value, the more preferred. The route sent from AR1 on AR3 can be increased by using the Route-policy command to increase the value of the local preference attribute, or AR4 The route sent by AR2 uses the route-policy command to reduce the value of the local priority attribute.
All of the above methods can complete AR3 and AR4 access 10.1.1.1, preferably using the AR1-AR3 link.
That is all I want to share with you!



