Link connectivity determines the stability and availability of a network. Therefore, link detection plays an important role in network maintenance. BFD cannot be used for link detection in all scenarios. For example, a simpler method is required for link detection between different ISPs.
Permanent advertisement of static routes provides a simple, low-cost link detection mechanism and improves compatibility between Huawei and non-Huawei devices. If service traffic needs to be forwarded along a specified path, you can ping the destination addresses of static routes to detect link connectivity.
When permanent advertisement of static routes is configured, static routes that cannot be advertised are still preferred and added to the routing table in the following cases:
If an outbound interface configured with an IP address is specified for a static route, the static route is always preferred and added to the routing table regardless of whether the outbound interface is Up or Down.
If no outbound interface is specified for a static route, the static route is always preferred and added to the routing table regardless of whether the static route can be iterated to an outbound interface.
In addition, you also need to control the priority and prefix length of a static route to enable ping packets to always be forwarded through this static route. The permanent advertisement mechanism provides a way for you to monitor services and detect link connectivity.
A device enabled with this feature always stores static routes in its IP routing table, regardless of whether the static routes are reachable. If a path is unreachable, the corresponding static route may become a blackhole route.
In Figure 1, border routers BR1, BR2, and BR3 belong to ISP1, ISP2, and ISP3 respectively. There are two links between BR1 and BR2, Link A and Link B. However, ISP1 requires that service traffic be forwarded to ISP2 over Link A without traveling through ISP3.
An External Border Gateway Protocol (EBGP) peer relationship is established between BR1 and BR2, making them BGP peers. For service monitoring purposes, a static route destined for BR2 at 10.1.1.2/24 is configured on BR1, and permanent advertisement of static routes is enabled on BR1. The interface that connects BR1 to BR2 is specified as the outbound interface of the static route. The network monitoring system periodically pings 10.1.1.2 to determine the status of Link A.
If Link A is working properly, BR1 forwards ping packets over Link A. If Link A becomes faulty, the static route is still preferred because permanent advertisement of static routes is enabled, despite the fact that service traffic can reach BR2 over Link B. BR1 still attempts to forward ping packets over Link A, but fails. This scenario also applies to BGP packets, resulting in a link fault that interrupts the BGP peer relationship. The monitoring system detects service faults as returned in the ping result and prompts maintenance engineers to rectify the faults before services are affected.