In this article we will discuss about HSRP and do a lab on it. Quick reminder about HSRP + Hot Standby Router Protocol (HSRP) is a Cisco proprietary protocol. + With HSRP, two or more devices support a virtual router with a fictitious MAC address and unique IP address + Hosts use this IP address as their default gateway and the MAC address for the Layer 2 header + The virtual routers MAC address is 0000.0c07.ACxx , in which xx is the HSRP group. Multiple groups (virtual routers) are allowed. + The Active router forwards traffic. The Standby router is backup and monitors periodic hellos (multicast to 224.0.0.2, UDP port 1985) to detect a failure of the active router. + The active router is chosen because it has the highest HSRP priority (default priority is 100). In case of a tie, the router with the highest configured IP address wins the election + A new router with a higher priority does not cause an election unless it is configured to preempt. HSRP States + Initial: HSRP is not running. + Learn: The router does not know the virtual IP address and is waiting to hear from the active router. + Listen: The router knows the IP and MAC of the virtual router, but it is not the active or standby router. + Speak: Router sends periodic HSRP hellos and participates in the election of the active router. + Standby: Router monitors hellos from active router and assumes responsibility if active router fails. + Active:Router forwards packets on behalf of the virtual router. Load balancing traffic across two uplinks to two HSRP routers with a single HSRP group is not possible. The trick is to use two HSRP groups: + One group assigns an active router to one switch. + The other group assigns another active router to the other switch. (Reference: SWITCH official Certification Guide)
That is all for the boring HSRP theory, let do a lab to understand more about HSRP! We will use the topology below for this lab: