Shubho.dev logo
Network LAN Cable

Convergence Time for RIP

You will usually read everywhere that RIP takes a considerably long time to converge. However, have you ever wondered why? Today we will see two scenarios and check the approximate convergence time it takes for RIP.

  1. When a link goes down, an update triggers with a poisoned route.
  2. When the routing updates stop (like in case of “passive-interface default“).

Here is the sample topology for your reference.

Sample Topology for RIP Timers
Sample Topology for RIP Timers

Triggered Update when a link goes down

To start with, let us assume the timer values. Let’s take the default values of RIP. The values are:

  1. Update timer - 30 seconds.
  2. Invalid timer - 180 seconds.
  3. Hold Down timer - 180 seconds.
  4. Flush timer - 240 seconds.

Let us also assume that all the four routers are synchronized meaning that their Update timers have started at the same time. Now the subnet 172.1.4.0 has been advertised to R2 by R1 which has the minimum metric of 2 for R2. Now at time t, R1 sends an update for the subnet 172.1.4.0 to R2.

Now let us shut down the interface Fa1/0 on R1. As a result, R1 sends a triggered update to R2 for 172.1.4.0 as a poisoned route with metric 16 (unreachable). In response, R2 will use poison reverse and send the same subnet with metric 16 back to R1. All these will take place within t+2 seconds. R2 now removes the subnet from its routing table. Now note that this time the subnet 172.1.4.0 is reachable via R4. R3 uses this information but not R2. R2 will have to wait for R3 to send an update for the subnet. R3 sends this update to R2 around t+30 seconds. Now R2 installs this route for subnet 172.1.4.0 via R3. All the routers have synchronized the timers as per our assumption. It takes around 30 seconds for R2 to learn the new path to the subnet. Please note in real use cases this is never the case so that the convergence time will vary between 20 to 50 seconds.

Updates do not arrive any more

Let us assume the same timer values in this case too. We are not expecting any synchronization timer here. Let us bring down the Fa0/0 interface on R1. Now, in this case, there is no triggered update from R1 towards R2 as it is not possible for R1 to send that to R2. After the interface is brought down on R1, R2 doesn’t receive any update for the subnet 172.1.4.0 from R1. So it waits till its Invalid timer (180 secs) expires. After this, R1 sets the Hold Down timer to 180 secs, and the count down begins for it to become 0.

Please note meanwhile R3 might send an update for the subnet 172.1.4.0 towards R2. However, this will only be of a higher metric than what R2 had, so during the hold down period R2 will not use this route. When either the Hold Down timer or Flush timer (240 seconds) expires, whichever comes first, the new route is used. Now since flush timers start along with the Invalid Timer, it needs to run for 60 more seconds for the route to flush. When this happens, the router removes even the Hold Down timer. Hence, R2 waits for 120+60=240 secs for the route to flush. Now R2 needs to wait for the next update from R3 which can take from 1 to 30 seconds. So during this scenario, the convergence takes a total of 240 to 270 seconds, which is a very long period for routes to converge.

Conclusion

The convergence time is quite high in case of RIP. Another IGP like OSPF and ISIS solves this issue quite well, and hence they are mostly used nowadays for large network installations.

Featured Image courtesy Jordan Harrison at Unsplash