HSRP vs VRRP vs GLBP Explained: One Gateway, Two Routers
Every device on a network points at one default gateway. If that gateway is one physical router, its failure strands the whole subnet. HSRP, VRRP and GLBP let two routers share one virtual gateway address so a backup takes over when the first fails. This guide explains how the trick works, how the three protocols differ — who is active, who waits, who answers, and who actually shares the load — and why repeated %HSRP-4-STATECHANGE messages mean the routers have stopped hearing each other, not that the protocol is broken.
The short answer
What are HSRP, VRRP and GLBP? They are three ways for two routers to pretend to be one default gateway. Hosts are configured with a virtual gateway address that belongs to no single box. The routers elect one of themselves to do the work; if it fails, the other quietly takes over the same address, and no host changes anything. HSRP is Cisco's original version (one Active, one Standby). VRRP is the open standard version of the same idea (one Active — traditionally called Master — and one or more Backups). GLBP is Cisco's load-balancing version: one Active Virtual Gateway answers for the address, but it hands different hosts different forwarders, so both routers carry traffic at once.
Think of a shop with one door. If the door jams, nobody gets in — even if the building has a second door round the back that nobody was told about. These protocols put a sign over a doorway that is not tied to one physical door: two staff agree which of them stands at the sign and waves people through, they keep checking on each other with a quiet "still there?" every few seconds, and if the answers stop, the other steps up to the same sign. Customers never learn a new entrance. GLBP is the version where the person at the sign sometimes points a customer to the second door on purpose, so both doors get used.
Why one gateway is a single point of failure
A host that wants to reach anything outside its own subnet sends the traffic to its default gateway and thinks no more about it. That gateway address is burned into every host's configuration — handed out by DHCP, typed in statically, baked into printers and cameras that nobody wants to touch. Put that address on one router and the router becomes a trapdoor under the whole subnet: the switches can be perfect, the uplinks diverse, the servers dual-homed, and one dead gateway still strands every host, because every host is still faithfully sending its traffic to an address nobody answers for any more.
All three protocols solve this the same way, and the trick has three parts. One: invent a virtual IP address for the gateway, separate from either router's real address (VRRP alone allows the virtual address to be one router's real address — that router is then called the address owner and always wins). Two: give that virtual IP a virtual MAC address, derived from the group number, so it is identical no matter which router is working. Three: run an election, forward as the winner, keep checking with hellos, and on failure let the next router start answering for the same IP and the same MAC. Because neither address changes, hosts do not reconfigure and switches barely notice — the virtual MAC simply starts arriving on a different port.
The standby does no forwarding. Its whole job is listening — which is why a broken hello path looks exactly like a dead active router.
The three protocols, side by side
| Feature | HSRP | VRRP | GLBP |
|---|---|---|---|
| Whose protocol | Cisco proprietary (described in RFC 2281, an informational RFC) | Open IETF standard — VRRPv3 is RFC 5798, updated by RFC 9568 | Cisco proprietary, no RFC |
| Roles | Active and Standby (any others Listen) | Active (traditionally Master) and Backup | AVG (Active Virtual Gateway) plus up to four AVFs (Active Virtual Forwarders) |
| Who forwards | The Active only | The Active/Master only | Every AVF, for the hosts handed its virtual MAC |
| Load balancing | Not within one group — use two groups with opposite actives and split the hosts | Not within one group — same two-group trick | Built in: round-robin (default), weighted, or host-dependent ARP replies |
| Priority | 0–255, default 100 | 1–254, default 100; 255 is reserved for the address owner | 1–255, default 100 (a separate weighting, also default 100, steers load) |
| Preempt by default | Off | On | Off for the AVG role (forwarder preemption is on, with a delay) |
| Keepalive | Hello 3 s, hold 10 s, UDP port 1985 to 224.0.0.2 (v1) or 224.0.0.102 (v2) | Advertisement 1 s, failure detected after about three missed, IP protocol 112 to 224.0.0.18 | Hello 3 s, hold 10 s, UDP port 3222 to 224.0.0.102 |
| Virtual MAC | v1: 0000.0c07.acXX (group 0–255); v2: 0000.0c9f.fXXX (group 0–4095) | 00-00-5E-00-01-XX for IPv4, 00-00-5E-00-02-XX for IPv6 (VRID 1–255) | 0007.b4XX.XXYY — one per forwarder, not one per group |
| Virtual IP can be a real interface address | No — it must be a spare address | Yes — that router becomes the owner, priority 255 | No — it must be a spare address |
Read the table by the rows that change behaviour, not by the rows that change spelling. Active versus Master is spelling — the job is identical. Three rows actually matter in a design: whose protocol it is (the moment a second vendor appears, HSRP and GLBP are off the table and VRRP is the answer), who forwards (GLBP is a different shape, not a different dialect), and preempt by default (the row that explains most "why did it move back?" and "why didn't it move back?" tickets).
HSRP: the states are the story
HSRP is the one you will meet most often on Cisco campuses, and it is the one whose log message brought most readers here, so it earns the deepest section. A router in an HSRP group is in one of six states. Initial is just switched on. Learn means it does not yet know the virtual IP and is waiting to hear it from the active router. Listen means it knows the address, hears the leader, and is neither active nor standby — the state of every group member beyond the first two. Speak means it is taking part in the election, sending hellos and arguing its priority. Standby is the named understudy: it hears the active router's hellos and will take over if they stop. Active answers ARP requests for the virtual IP with the virtual MAC and forwards the traffic.
Two defaults define HSRP's character. First, preemption is off: if the priority-110 router fails, the priority-100 standby takes over — and when the 110 comes back, it politely becomes standby and stays there until the next failure. Designs that want the "main" router to be active in steady state must say so explicitly with standby 1 preempt on that router. Second, tracking is how HSRP notices a half-dead router: a router can be alive, sending hellos, and useless because its uplink is down. Interface tracking lowers its priority when a watched uplink fails, so the standby — if its priority is now higher, and it is allowed to preempt — takes over. A gateway pair where only the box itself is monitored protects against a dead box and nothing else.
The commands tell the story at a glance. show standby brief lists every group, its priority, a P flag where preemption is configured, the state, and the virtual IP. show standby adds the timers, the active and standby real addresses, and how long ago the last state change happened — that last line is the first thing to read after any complaint, because it turns "the gateway flapped" into a timestamp you can line up against everything else.
VRRP: the same play, in an open rulebook
VRRP was written, deliberately, to do HSRP's job as a vendor-neutral standard — which is why the mechanics feel familiar: a virtual IP, a virtual MAC, an election on priority with the highest real IP breaking ties, periodic advertisements instead of hellos, and one forwarder at a time. If you understand one, you understand the other's shape; what you must not do is assume the defaults travelled across.
Three differences bite in practice. Preemption is on by default — a recovered higher-priority router takes the gateway back automatically, which is usually what you want and occasionally a second, unplanned interruption in the middle of an incident. Failover is faster out of the box: advertisements default to one second and a backup declares the leader down after roughly three missed advertisements plus a small priority-based skew, so a default VRRP failover lands in about three seconds where a default HSRP one can take the full ten-second hold time. The virtual IP may be a real address: configure the virtual address equal to one router's interface address and that router is the owner, with priority 255, always the forwarder while it lives — a trick HSRP and GLBP cannot do, because their virtual address must be a spare.
GLBP: the one that shares the work
HSRP and VRRP both leave an expensive router idle. The standard workaround is carpentry: build two groups, make router A active for the first and router B active for the second, and hand half the hosts each gateway. GLBP was Cisco's answer to doing it in one group. It splits the job in two. The AVG (Active Virtual Gateway) owns the virtual IP and answers every ARP request for it — but it answers different hosts with different virtual MAC addresses. Each of those MACs belongs to an AVF (Active Virtual Forwarder), one of up to four group members, which forwards the traffic sent to its MAC. Same gateway IP for everyone; different actual routers underneath.
How the AVG hands the MACs out is the load-balancing method: round-robin (the default) cycles through the forwarders in turn; weighted hands out a forwarder's MAC in proportion to its configured weighting, so a bigger router earns a bigger share; host-dependent derives the choice from the host's own MAC address, so a given host keeps the same forwarder for as long as the set of forwarders does not change. The honest limits matter as much as the mechanism: balancing is per host, not per flow, so one very heavy host still rides one forwarder; and the share is only as even as the host count and ARP timing make it. GLBP also has the subtlest failure bookkeeping of the three — if a forwarder dies, another member takes over its virtual MAC as well as its own, so no host's learned gateway MAC ever goes stale.
What %HSRP-4-STATECHANGE actually means
The decoder entry for %HSRP-4-STATECHANGE walks the message itself; its sample reads Vlan10 Grp 1 state Standby -> Active — on that VLAN interface, in group 1, this router just moved from standby to active. Read it with one question: did something actually fail?
Once, alongside a real failure, it is the design working. The active router died, its hellos stopped, the hold timer expired, the standby promoted itself. Users may have felt up to ten seconds of pause on default timers; that is the price the defaults chose. Repeatedly, with no failure, it is a diagnosis, not an event. A standby promotes itself for exactly one reason: it stopped hearing hellos. If the active router is up and forwarding the whole time, then the hellos are being lost on the path between the two routers — a congested or erroring link between them, an access list or control-plane filter eating UDP 1985 or the multicast address, inconsistent timers or group configuration so the two are not really in the same conversation, or a VLAN that exists on one side's trunk and not the other's. The standby seizes the gateway, hears the real active again, hands it back, loses the hellos again — and users report random dropouts that line up with the log, one state change at a time.
So the working order is: read show standby on both routers (who is active, who is standby, when did it last change, do the timers and group agree?), then fix the hello path — the link, the filters, the trunk — and only then judge the protocol. Tuning timers on a flapping pair makes it flap faster. The same logic reads across to the other two protocols: a VRRP pair that keeps re-electing is losing advertisements (IP protocol 112 is a common casualty of filters written for TCP and UDP only), and a GLBP group that keeps reassigning forwarders is losing hellos on UDP 3222.
Choosing, in one paragraph each
Choose VRRP when more than one vendor will ever sit at that gateway, when you want the faster default failover, or when standards compliance is a requirement in its own right. It is the only one of the three that is a real multi-vendor standard, and its defaults are the most modern of the three. Choose HSRP when the gateway layer is Cisco end to end and the team's runbooks, tracking setups and muscle memory are already built around it — version 2, with preemption set deliberately on the router you want in charge, and tracking on the uplinks that actually matter. Choose GLBP only when a single Cisco group must share load without the two-group carpentry, and you accept per-host balancing and a Cisco-only, older protocol to get it. And whichever you choose, write down the intended steady state — which box should be active for which group, and whether it should take the role back — because every one of these incidents starts with two engineers holding different pictures of normal.
For the switching ground these gateways stand on, read VLANs, trunks, and spanning tree; for what hosts experience while a gateway is healthy but the path beyond it is not, read what happens when you ping across VLANs.
Try it yourself
Paste a two-router gateway configuration into the free Network Config Verifier and check the pair agrees on the group, the virtual address and the priorities you intended, then draw the same pair with the free Config-to-Topology Mapper to see both routers attached to the subnet they share. And the next time the log shows %HSRP-4-STATECHANGE more than once, open the decoder entry for %HSRP-4-STATECHANGE and work its checks in order — starting with the hello path, not the protocol.
Fact-check sources: HSRP roles, states, priority and timers, UDP 1985, multicast addresses and virtual MAC formats for versions 1 and 2, and preemption off by default — Cisco's HSRP configuration and troubleshooting documentation, with RFC 2281 as the informational description of version 1. VRRP election, priority range and the reserved 255 for the address owner, the one-second default advertisement interval and master-down calculation, IP protocol 112, multicast 224.0.0.18, virtual MAC formats for IPv4 and IPv6, and preemption on by default — RFC 5798 (VRRPv3), as updated by RFC 9568. GLBP's AVG/AVF split, the maximum of four active virtual forwarders, the three load-balancing methods with round-robin as default, UDP 3222, multicast 224.0.0.102, and the 0007.b4xx.xxyy virtual MAC format — Cisco's GLBP configuration documentation. The %HSRP-4-STATECHANGE sample message and its repeated-change meaning are quoted from the site's own decoder entry, which is sourced from Cisco HSRP documentation.
Related guides
- HSRP, VRRP and GLBP are first-hop redundancy protocols: two or more routers present one virtual IP address (and a virtual MAC address) as the default gateway, so hosts never change their settings when the working router changes.
- HSRP (Cisco, Active/Standby) and VRRP (open IETF standard, Active/Master and Backup) each forward through one router at a time; the other waits. GLBP (Cisco, AVG/AVF) is the only one of the three that shares traffic by design, by handing different hosts different virtual MAC addresses for the same virtual IP.
- Priority decides who leads (default 100 in all three) and the highest real IP breaks a tie. Preemption — whether a recovered higher-priority router takes the role back — is off by default in HSRP, on by default in VRRP, and off by default for the GLBP gateway role; that one default explains most surprise takeovers and most takeovers that never happen.
- A state-change message once, during a real failure, is the system working. The same message repeating means the standby keeps losing the hello/advertisement path and seizing a gateway it then has to hand back — fix the path the hellos travel on, not the protocol.