HSRP
- Hot Standby Router Protocol is an FHRP protocol
- HSRP uses a Virtual IP (VIP) and MAC address to allow for automated gateway failover
- The hosts use the VIP as their default gateway address
- If the active gateway fails, the standby gateway will take over
- Hello messages are sent ever 3 seconds by default by routes in the active, standby, or speak states
- Only routers in the standby state listen for routers, and takes over if the span between hello messages exceeds the hold time (def. 10 seconds)
- VRRP (Virtual Router Redundancy Protocol) is identical to HSRP, except it uses
vrrp instead of standby for its configuration
FHRP Virtual MAC Addresses
- Virtual MAC addresses
- HSRPv1: 0.c07.acXX or 00:00:0c:07:ac:XX
- HSRPv2: 0.c9f.fXXX or 00:00:0c:9f:fX:XX
- VRRP: 0.5e00.1XX or 00:00:5e:00:01:XX
- V = 5e00
- 05e001 (Oh 5-ee hundred and 1)
- GLBP: 7.b400.XXYY or 00:07:b4:00:XX:YY
- G =/= 5, so G = b400
- 7B400
FHRP
- First Hop Redundancy Protocols use a Virtual IP (VIP) and MAC addresses to allow for automated failover
- The network clients use the VIP as their Default Gateway
- If a physical gateway fails, another gateway will take over
FHRP Virtual MAC Addresses
- Virtual MAC addresses
- HSRPv1: 0.c07.acXX or 00:00:0c:07:ac:XX
- HSRPv2: 0.c9f.fXXX or 00:00:0c:9f:fX:XX
- VRRP: 0.5e00.1XX or 00:00:5e:00:01:XX
- V = 5e00
- 05e001 (Oh 5-ee hundred and 1)
- GLBP: 7.b400.XXYY or 00:07:b4:00:XX:YY
- G =/= 5, so G = b400
- 7B400
- 224.0.0.2
- 224.0.0.9
- 224.0.0.18
- 224.0.0.102
FHRP Protocols
-
Hot Standby Router Protocol (HSRP)
- #Cisco-Proprietary ; deployed in active/standby pairs
- This is what's covered in the CCNA
-
Virtual Router Redundancy Protocol (VRRP)
- Open standard; deployed in active/standby pairs
- Almost identical to HSRP.
- One difference is HSRP uses "standby" and VRRP uses "vrrp"
-
Gateway Load Balancing Protocol (GLBP)
- #Cisco-Proprietary ; supports active/active load balancing across multiple routers on the same subnet
-
FHRP-activated routers communicate with each other by sending multicast Hello messages
-
When FHRP is configured, the Virtual IP address should be configured as the default gateway for hosts
-
The active FHRP router responds to ARP requests with a virtual MAC address
-
HSRP uses Active and Standby routers
- When HSRP Standby router switches to active, it will send gratuitous ARP messages
- The HSRP active router is determined by Highest priority, then highest IP address
- The default priority is 100
- HSRPv1
- HSRPv1 Mutlicast address is 224.0.0.2
- Virtual MAC address format: 0000.0c07.acXX
- (XX is HSRP group number)
- This can be shortened to 0.c07.acXX
- HSRPv2
- HSRPv2 Multicast address is 224.0.0.102
- Virtual MAC address format: 0000.0c9f.fXXX
- (XXX is the HSRP group number)
- This can be shortened to 0.c9f.fXXX
- HSRP Commands
- Assign virtual IP
Config-if# standby (group number) ip (IP address)
- Configure priority
Config-if# standby (group number) priority (Priority number)
- Configure Preemption
Config-if# standby (group number) preempt
- Configure Version 2
Config-if# standby version 2
-
VRRP uses Master and Backup routers
- VRRP Multicast address is 224.0.0.18
- VRRP Virtual MAC address format is 0000.5e00.01XX
- (XX = VRRP group number)
- This can be shortened to 0.5e00.1XX
-
Gateway Load Balancing Protocol
- Load balances among multiple routers on the same subnet
- A single Active Virtual Gateway (AVG) is elected
- The AVG assigns up to four Active Virtual Forwarders (AVFs)
- GLBP - Gateway Load Balancing Protocol - Cisco Systems
- GLBP Multicast address is the same as HSRPv2, 224.0.0.102
- GLBP virtual MAC address format is 0007.b400.XXYY
- This can be shorted to 7.b400.XXYY
- (XX = GLBP group number, YY = AVF number)
- AVF = Active Virtual Forwarders
OSI or TCP/IP Layer
CCNA Exam Topic
Contributors
Sources
HSRP operations
- Both routers have a normal physical IP address and MAC address on their HSRP interface
- Unique addresses area used on both routers
- They both also have the HSRP VIP and MAC address configured on the interface
- The same addresses are used on both routers
- When they come online, one is elected to HSRP active router, the other is standby
- The active router owns the virtual IP and MAC address and responds to ARP requests
- All traffic for the VIP goes through the active router
- The routers send hello messages to each other over their HSRP interface
- If the standby router stops receiving hellos from the active, it will transition to be the active router
- It will take ownership of the VIP and MAC address and respond to ARP requests
HSRP Router States
- There are 6 HSRP states
- Init
- When the link first comes up
- Learn
- The HSRP device is attempting to learn the VIP
- Listen
- The device has learned the VIP
- The device is listening for hello messages from other (active/standby) HSRP devices
- If a device is not elected to either active or standby, it remains in the Listen state
- Speak
- The device sends hello messages and participates in the Active router election
- Standby
- The device is actively listening to hello messages from the Active router
- The default hold time is 10 seconds, roughly 3x the hello time
- Active
- The device receives data for and manages the VIP
- Sends hello messages ever 3 seconds (by default)
Advanced Topics
- Priority and Preemption
- Router priority can be set, with the higher value being preferred
- Default value is 100
- Preemption allows a router to take
Active when it comes online
- Default, preemption is disabled because it can be more stable if there is a fault with the primary router
- HSRP Version
- Version 2 introduced minor improvements
- Default version is 1
- Both routers must be on the same version
- Standby Groups
- Multiple HSRP "Standby groups" can be configured on interface, allowing for "load balancing" between VLANs or different clients
- e.g., R1 is priority in standby 1 10.10.10.1/24, and R2 is priority in standby 2 10.10.20.1/24
HSRP Configuration
- Configure both router interfaces with their IP and "standby IP" (Virtual IP)
- Example: VIP is 10.10.10.1
R1Config# int g0/1
Config-if# ip address 10.10.10.2 255.255.255.0
Config-if# no shut
Config-if# standby 1 ip 10.10.10.1
Config-if# standby 1 priority 110
Config-if# standby 1 preempt
Config-if# standby version 2
R2Config# int g0/1
Config-if# ip address 10.10.10.3 255.255.255.0
Config-if# no shut
Config-if# standby 1 ip 10.10.10.1
Config-if# standby 1 priority 90
Config-if# standby version 2
- Verification
#sho standby
OSI or TCP/IP Layer
CCNA Exam Topic
Contributors
Sources