HSRP (Hot Standby Routing Protocol)

Hello David

Thanks for the clarification. Let’s take a look at the diagram from the lesson once again and look at a couple of best practices that should be employed with HSRP and routing protocols. Then we’ll take a look at the problems that preemption can cause:

Now imagine that OSPF is configured between SW1, SW2, and R3. If you leave OSPF configurations at their defaults, R3 will load balance traffic destined for the 192.168.1.0/24 network across both SW2 and SW3. Ideally, we want OSPF to forward traffic to the active HSRP device for that particular network.

For this reason, it is best practice to ensure that OSPF uses the active router in the HSRP arrangement to forward traffic. So, using a mechanism such as IP SLA to change the metric, you can ensure that this takes place.

Let’s say SW1 is the active router, and OSPF is configured accordingly to send traffic from R3 to our network via SW1. Now let’s say that the Gi0/1 interface goes down. SW2 will immediately take over as the active router, however, traffic from R3 will continue to go to SW1. SW1 must then route that traffic to SW3 to be sent to the intended host. Traffic from the host will also be routed via SW2 → SW1 → R3 which is indeed suboptimal. This will take place until OSPF reconverges, which can take several hundreds of milliseconds, or even up to a second depending on the size of the routing table.

Things get even more difficult if the Gi/1 interface on SW1 begins to flap. Then, the active router will continually alternate between SW1 and SW2, causing even more havoc with OSPF routing.

For more information on how HSRP interacts with various routing protocols as well as spanning tree mechanisms, take a look at this excellent Cisco documentation that details the best practices that should be used to ensure the best performance for high-availability features.

I hope this has been helpful!

Laz