Lab 13: HSRP — Redundant Default Gateway
Give the LAN a gateway that survives router failure: two routers share virtual IP 192.168.1.254 via HSRP — one Active, one Standby, failover in seconds. Difficulty: Intermediate+ · Time: ~30 min.
Lab objectives
- Configure HSRP group with a virtual IP on both routers
- Control the Active election with priority + preemption
- Verify roles with show standby brief
- Prove failover with a continuous ping
Topology & addressing
2× routers, LAN-facing interfaces on the same switch/subnet: R1 Gi0/0 = 192.168.1.2/24, R2 Gi0/0 = 192.168.1.3/24. PCs use gateway 192.168.1.254 (the virtual IP).
Step-by-step configuration
R1: interface gi0/0standby 1 ip 192.168.1.254standby 1 priority 110standby 1 preempt | Higher priority + preempt → R1 wins Active |
R2: interface gi0/0standby 1 ip 192.168.1.254 | Default priority 100 → Standby |
show standby brief | Confirm Active/Standby roles and virtual IP |
Verification
Start a continuous ping from a PC to 192.168.1.254, then shut R1's interface — a couple of drops, then replies resume as R2 takes Active (show standby brief confirms). Re-enable R1: with preempt, it reclaims Active. That's zero-touch gateway resilience.
Next lab: labs hub · test yourself: CCNA practice test.
Frequently asked questions
What is the virtual IP in HSRP?
An address owned by the HSRP group, not any single router — hosts use it as their gateway, and whichever router is Active answers for it.
Why is preempt needed?
Without it, a recovered higher-priority router stays Standby; preempt lets it reclaim the Active role automatically.
How fast is failover?
With default timers a few seconds; tuned hello/hold timers bring it lower. Watch the ping stream during the test.
Related articles
Want hands-on training?
Learn this on real Cisco lab devices with placement support at Attila Technologies, Ahmedabad.