Guide
First hop redundancy: HSRP, VRRP and GLBP (CCNA and CCNP)
First hop redundancy protocols give hosts a stable default gateway while routers provide backup or share forwarding. This guide explains HSRP, VRRP and GLBP behavior, their defaults, key commands and common failure cases.
3 parts · video · 26 practice questions
HSRP: one virtual gateway with an active router
Hosts normally send off-subnet traffic to a configured default gateway. HSRP, a Cisco proprietary protocol, lets multiple routers on the same LAN present one virtual IP address and virtual MAC address. Configure hosts with the virtual IP. The active router forwards for it and answers ARP with the virtual MAC; a standby router can take over after failure. Hosts keep the same gateway configuration across the change. Its role names are active and standby.
- HSRPv1 default
- Version 1 is the default
- HSRPv1 groups
- 0 to 255
- HSRP priority
- 1 to 255; default 100
- Preemption
- Disabled by default
On Cisco IOS XE Catalyst switches, HSRP version 1 is the default. Its group numbers range from 0 to 255, and its virtual MAC format is 0000.0C07.ACXX, where XX is the group number in hexadecimal. Version 2 supports group numbers 0 through 4095, uses virtual MAC addresses in the range 0000.0C9F.F000 to 0000.0C9F.FFFF, and sends hello packets to multicast address 224.0.0.102 instead of version 1's 224.0.0.2. The interface command standby version 2 selects version 2. HSRPv1 and HSRPv2 do not interoperate on an interface, so peers must use the same version.
HSRP priority ranges from 1 to 255 and defaults to 100. A higher priority is preferred when preemption is enabled; if priorities are equal, the current active router remains active. Cisco documents the higher interface IP as the tie breaker when no priorities are set and no router is designated. A higher-priority router does not take the active role away from a working active peer unless preemption is enabled. Preemption is disabled by default. standby <group> preempt lets the higher-priority router take over when eligible. A preempt delay postpones that takeover so routing and forwarding state can recover after a reboot.
HSRP monitors the local interface running the group, but that alone cannot detect a failed WAN uplink elsewhere. Track an interface or tracking object so a failure reduces the HSRP priority. The default decrement is 10. Configured decrements for multiple failed tracked objects are cumulative; when failed tracked objects have no configured decrement, the default decrement of 10 is noncumulative. A decrement of 20 subtracts 20 from the priority. For the other router to take over because of this change, it must have the higher resulting priority and preemption enabled. Tracking changes gateway preference; it does not repair the failed path.
Use show standby to inspect the group state, active and standby peers, priority, preemption, tracking and virtual IP; show standby brief gives a concise overview. If the expected router is not active, check that both peers have compatible group settings and version, that the virtual IP is correct, and that the priority difference and preemption state produce the intended election. If the active router remains active after an uplink failure, check that the uplink or an object representing its reachability is tracked, that the decrement is large enough to change the ranking, and that the alternate router can preempt.
interface GigabitEthernet0/0
standby version 2
standby 1 ip 10.0.1.254
standby 1 priority 200
standby 1 preempt delay minimum 30
standby 1 track 10 decrement 20
show standbyVRRP and GLBP: standards based backup and active sharing
VRRP is an IETF standard with multi-vendor interoperability; HSRP is Cisco proprietary. Both VRRP and HSRP give hosts a shared virtual default gateway IP. VRRP calls the forwarding router the master or virtual primary and the other routers backups; HSRP calls them active and standby. For VRRPv2, the virtual MAC format is 0000.5E00.01XX, where XX is the group ID in hexadecimal. Do not confuse it with HSRP v1's 0000.0C07.ACXX or HSRP v2's 0000.0C9F.FXXX format.
- VRRPv2 virtual MAC
- 0000.5E00.01XX
- VRRP backup priority
- 1 to 254; default 100
- VRRP address owner
- Priority 255
- GLBP virtual MACs
- Up to four per group
VRRP backup priorities are configurable from 1 to 254 and default to 100. A router that owns the virtual IP has priority 255. Higher priority wins an election, with a higher interface IP breaking a tie. VRRP preemption is enabled by default, so a higher-priority backup that returns can take the master role from the router that became master during its absence. The no vrrp preempt command disables that behavior. VRRP object tracking can lower a router's priority when an interface, route or tracked IP SLA object fails; a backup takes over only if its resulting priority is higher. The IP address owner's priority is fixed at 255 and tracking cannot lower it.
GLBP offers gateway load sharing with one virtual IP. The Active Virtual Gateway (AVG) answers ARP requests for that IP and assigns virtual MAC addresses. Hosts can therefore retain the same gateway IP but learn different gateway MACs. The routers that forward traffic for those MACs are Active Virtual Forwarders (AVFs). A GLBP group supports up to four virtual MAC addresses and thus up to four active virtual forwarders. HSRP and VRRP normally have one active/master forwarder per group; GLBP can have multiple forwarders carrying traffic at once. Its virtual MACs use the 0007.B400 prefix.
The AVG is an ARP responder and coordinator, not the only traffic forwarder. The AVF that owns a MAC forwards packets addressed to it. HSRP's active and standby labels describe the router's role for that group's virtual gateway; a router can be active in one HSRP group and standby in another. GLBP's load balancing occurs when the AVG assigns MACs in ARP replies, so host assignments and traffic patterns determine how evenly traffic is shared. Cisco notes that sub-second convergence requires tuning FHRP timers and can affect switch CPU resources, so it is not a GLBP default guarantee. If an AVF fails, another group member can assume forwarding responsibility for its virtual MAC; if the AVG fails, a backup can become the AVG.
interface GigabitEthernet0/0
vrrp 1 ip 10.0.1.254
vrrp 1 priority 110
! VRRP preemption is enabled by default; use no vrrp 1 preempt to disable it
! GLBP uses glbp <group> ip <virtual-address> on supported IOS/IOS XE interfacesReferences (6)
- FHRP Configuration Guide, Cisco IOS XE 17: VRRP (Catalyst 9000)
- Consolidated Platform Configuration Guide, Cisco IOS 15.2(7)E: HSRP and VRRP (Catalyst 2960-XR)
- IP Addressing Services Configuration Guide, Cisco IOS XE 17.18.x: GLBP (Catalyst 9300)
- IP Addressing Services Configuration Guide, Cisco IOS XE 17.7.x: Enhanced Object Tracking (Catalyst 9300)
- IP Multicast Routing Configuration Guide, Cisco IOS 15.2(3)E and later (Catalyst 3750-X and 3560-X)
- Campus LAN and Wireless LAN Solution Design Guide
CCNP depth: tracking, convergence and operational checks
Tracking ties gateway preference to the path beyond the LAN. Without tracking, a router can remain HSRP active even when its WAN path is down, black-holing traffic sent to it. HSRP can track an interface or an object such as IP reachability; VRRP supports interface and object tracking, including IP SLA tracking. On a tracked failure, the configured decrement is applied to the current priority. Compare the changed priority with the peer's priority before predicting a takeover. The peer must also be able to become active or master under that protocol's preemption rules.
- HSRP preempt delay
- minimum <seconds>
- Convergence protocols
- OSPF, EIGRP or BGP
For HSRP, a router with higher priority but no standby <group> preempt stays standby while a working peer remains active. With preemption enabled, standby <group> preempt delay minimum <seconds> delays reclaiming the active role. This is useful after a restart because routing protocols such as OSPF, EIGRP or BGP and forwarding tables may need time to converge. Without enough delay, the recovering router can attract traffic before it has a usable route. Delay does not guarantee convergence by itself, so choose a value appropriate to the network and verify routing before takeover.
Troubleshoot from state to cause: use show standby for HSRP roles and priority; check the configured virtual gateway, group and version; inspect tracking state and decrement; then confirm the peer's priority and preemption setting. For VRRP, verify the master and backup roles, priority, tracked object state and whether preemption was disabled. For GLBP, distinguish the AVG, which controls ARP assignment, from AVFs, which forward for virtual MACs. A host learning one GLBP virtual MAC does not mean the other AVFs are idle, and an AVG change alone does not mean all forwarding has stopped.
track 10 interface GigabitEthernet0/1 line-protocol
interface GigabitEthernet0/0
standby 1 track 10 decrement 20
standby 1 preempt delay minimum 30
show standby
show track 10References (4)
- IP Addressing Services Configuration Guide, Cisco IOS XE 17.18.x: HSRP (Catalyst 9300)
- FHRP Configuration Guide, Cisco IOS XE 17: VRRP (Catalyst 9000)
- IP Addressing Services Configuration Guide, Cisco IOS XE 17.18.x: GLBP (Catalyst 9300)
- IP Addressing Services Configuration Guide, Cisco IOS XE 17.7.x: Enhanced Object Tracking (Catalyst 9300)
Check your understanding
First hop redundancy: HSRP, VRRP and GLBP (CCNA and CCNP)
All 3 sections · no timer
Unlimited retries
Questions from every section are combined into one assessment. Answer them all correctly to complete the article.
Your completion saves in this browser. Sign in to sync it to your account.