Route Flapping Occurs Due to Route Import

Publication Date:  2015-10-14 Views:  522 Downloads:  0
Issue Description
As shown in Figure 1-1, Router_1 and Router_2 are connected. OSPF and IS-IS are used between Router_1 and Router_2. On Router_1, a static blackhole route with IP address 192.168.1.0 is configured o, an OSPF process is created, and static routes are imported. On Router_2, OSPF routes are imported into IS-IS. However, when service runs on the network, information about the static blackhole route intermittently disappears and appears in the routing table of Router_2.

Figure 1-1 Route flapping

  • Configuration file of Router_1
#
isis 1   //Create an IS-IS process.
is-level level-1
network-entity 10.0000.0000.0001.00   //Set the NET to 10.0000.0000.0001.00. The system ID is 0000.0001 and the area ID is 10.0000.
#
interface GigabitEthernet1/0/0
ip address 10.1.1.1 255.255.255.252
isis enable 1    //Enable IS-IS process 1 on GE1/0/0.
#
ospf 10    //Create an OSPF process.
import-route static    //Import static routes.
area 0.0.0.0
  network 10.1.1.0 0.0.0.3
#
ip route-static 192.168.1.0 255.255.255.0 NULL0   //Configure the static blackhole route.
  • Configuration file of Router_2
#
isis 1   //Create an IS-IS process.
is-level level-1
network-entity 10.0000.0000.0002.00   //Set the NET to 10.0000.0000.0002.00. The system ID is 0000.0002 and the area ID is 10.0000.
import-route ospf 10 level-1    //Import the route information learned by OSPF.
#
interface GigabitEthernet1/0/0
ip address 10.1.1.2 255.255.255.252
isis enable 1    //Enable IS-IS process 1 on GE1/0/0.
#
ospf 10    //Create an OSPF process.
area 0.0.0.0
  network 10.1.1.0 0.0.0.3
Alarm Information
Router_1 generates the following alarms:

Jul  8 2014 10:40:27-05:13 Huawei %%01ISIS/4/ADJ_CHANGE_LEVEL(l)[0]:The neighbor of ISIS was changed. (IsisProcessId=[USHORT], Neighbor=[STRING], InterfaceName=[STRING], CurrentState=[STRING], ChangeType=[STRING], Level=[STRING])

Jul  8 2014 10:34:34-05:13 Huawei %%01ISIS/4/START_ENABLE_ISIS(l)[1]:ISIS [USHORT] enabled all ISIS modules.

Jul  8 2014 10:21:08-05:13 Huawei %%01OSPF/4/NBR_CHANGE_E(l)[2]:Neighbor changesevent: neighbor status changed. (ProcessId=[USHORT], NeighborAddress=[IPADDR], NeighborEvent=[STRING], NeighborPreviousState=[STRING], NeighborCurrentState=[STRING])

Jul  8 2014 10:21:08-05:13 Huawei %%01OSPF/4/NBR_CHANGE_E(l)[3]:Neighbor changesevent: neighbor status changed. (ProcessId=[USHORT], NeighborAddress=[IPADDR], NeighborEvent=[STRING], NeighborPreviousState=[STRING], NeighborCurrentState=[STRING])

Jul  8 2014 10:21:08-05:13 Huawei %%01OSPF/4/NBR_CHANGE_E(l)[4]:Neighbor changes event: neighbor status changed. (ProcessId=[USHORT], NeighborAddress=[IPADDR], NeighborEvent=[STRING], NeighborPreviousState=[STRING], NeighborCurrentState=[STRING])
Handling Process
Step 1 Check the routing table of Router_1 and information about the routes with IP address 192.168.1.0/24.

Run the display ip routing-table command on Router_1 to check the routing table.

Figure 1-2 Original routing table of Router_1



The route with IP address 192.168.1.0/24 is a static route with the priority of 60. A notification is sent to Router_1 after OSPF routes are imported into IS-IS on Router_2. Because the priority of the IS-IS routing protocol is 15 and is much higher than that of the static routing protocol, Router_1 changes the route with IP address 192.168.1.0/24 to IS-IS route.

Figure 1-3 Updated routing table of Router_1



Step 2 Check the routing table of Router_2 and the route with IP address 192.168.1.0/24.

Run the display ip routing-table command on Router_2 to check the routing table.

Figure 1-4 Routing table of Router_2



As shown in Figure 1-2, the route with destination network segment 192.168.1.0/24 is a static route. Because the route with destination network segment 192.168.1.0/24 on Router_1 is change to an IS-IS route, OSPF cannot import this route. As a result, the routing entry disappears (as shown in Figure 1-5) and appears (as shown in Figure 1-4) frequently in the routing table.

Figure 1-5 Updated routing table of Router_2



Step 3 Change the priority of the static route.

Route flapping occurs because the IS-IS route with higher priority replaces the static route with lower priority and OSPF cannot import this route.

To ensure that the IS-IS route does not replace the static route, change the priority of the static route on Router_1 to be smaller than that of the IS-IS route.

<Router_1> system-view
[Router_1] ip route-static 192.168.1.0 255.255.255.0 NULL0 preference 10

The route with network segment 192.168.1.0/24 is normal.
Root Cause
When static routes, OSPF routes, and IS-IS routes are imported by each other, the source route will be changed because the priority of each routing protocol is different.
Suggestions
Frequent route flapping consumes much bandwidth and CPU resources and even seriously affects the normal operation of a network. When routing protocols import routes from each other, exercise caution. In particular, when multiple routing protocol import routes from each other, route flapping or even a loop easily occurs.

END