Paul, welcome to RouterGod Online Magazine, it's great to talk
No worries mate, say, I'm sorry about the business between Vic
and the police, sometimes the little devil gets a might cranky.
Well everything seems to be OK now, why don't you explain HSRP to
OK (clears throat) let's talk about the Hot Standby Router
Protocol. HSPR is a way for two Cisco routers to share a
common virtual IP address while one router is actively routing
packets, the other router or routers are standing by in case the
active router fails. It's a very good way to provide fault
tolerance. In fact, if ya take a mind to, you can read RFC
2281 to learn a bit more about it.
So the routers share an IP address. How do the routers know
when one has failed?
Let's get back to the IP address, besides sharing an IP address,
that IP address has a common MAC address that the routers
share. It's like this, mate, you have a workgroup of say, I
don't know, 100 computers. Each one of these machines has been
configured with a default gateway, if these machines have used the
default gateway or router, they have it's MAC address in their ARP
cache. So since the routers in the HSRP group share an IP
address with a corresponding MAC address, when they fail over, the
workstations are unaware of the change. What they see, is a
How do the routers control all this?
Well mate, the routers in an HSRP group send and receive keep
alives using the multicast address of 188.8.131.52 and UDP port
1985. By default the hello interval is 3 seconds. Once 3
hello intervals pass without hearing from the active router, the
standby router automatically becomes the active router. Each
router is configured with a priority number, the router with the
highest priority number in a standby group is the active router,
everyone else just relaxes.
This must be very hard to configure...
No way mate, you only need 2 commands to do it, and 2 additional
commands to customize it. What's more, it's configured at the
interface that you want to participate in the standby group.
It's so easy, an American could do it!
No way! Really? What are the commands?
Well, first off, on the router that you want to be the active
router, go to the interface you want HSRP to run on, think up a
group number, all routers participating in this scheme must use the
same group number, also think up what IP address you want the HSRP
group to share. Now watch me type:
dingo(config-if)#standby 1 ip address
dingo(config-if)#standby 1 priority 100
So what we have here mate, is a standby group number of 1,
an IP address of 10.1.1.254 that the routers are going to
share, now let's configure the standby router:
fosters(config-if)#standby 1 ip address
fosters(config-if)#standby 1 priority 90
OK, the only thing different on the standby router is the
priority. The router with the highest priority becomes the
What if the active router, with the priority of 100 goes down and
comes back up, since it has the higher priority, will it become
Sorry mate, in that situation, if you want it to be the active
router again, you have to add the keyword preempt to the
dingo(config-if)#standby 1 priority 100 preempt
Hey Paul, what if the routers are connected to a WAN link, and
the routers are running fine, but the WAN link goes down, is there
any way to track that?
You said it my clever friend, the command is track.
Say you want to have HSRP failover if the WAN link goes down,
well just track the interface that the WAN link is connected
to, like so:
dingo(config-if)#standby 1 track s0 priority 11
Noticed that there is the keyword priority followed by a
number. That number is the number to subtract from the
router's own priority number to give it an adjusted priority number
if the interface it's tracking goes down. If the Serial 0
interface goes down, our router's priority goes from 100 to 89 which
will cause the standby router to become active since it has a
priority of 90. You might need this to happen if the standby
router is configured for DDR.
This has all been very interesting, welcome to America and thanks
for explaining HSRP!
No worries mate!
Visit the HSRP
Guide and the HSRP FAQ at
Cisco. Also see Cisco's exciting page on Configuring
HSRP. Remember, never charge less than $1000 to set up HSRP and
always get the money up front, before your customer sees that you
fully configured HSRP on 2 routers in less than 5 min!
Back to RouterGod Online