Step-by-Step With Cisco's Hot Standby Router Protocol - Page 2

 By Michael Burton
Page 2 of 2   |  Back to Page 1
Print Article

The Hot Swappable Router Protocol (HSRP) is a way to build redundancy into your network by allowing two or more routers to continuously test each other for connectivity, and take over if a router fails. For purposes of discussing a basic HSRP configuration, let's assume we want to make the 10.10.10./24 network dynamically redundant and have two building routers at our disposal.

Using HSRP terminology, both building routers together are referred to as a standby group and appear to the subnet as a single default gateway. Through an election process, one router is designated as active and the other router is designated as standby. Both the active and standby router listen to routing updates from the core router, but only the active router processes IP packets as the default gateway for the subnet. The active and standby routers are constantly sending "hello" packets back and forth. If the active router fails, as soon as a predetermined number of "hello" packets from the standby router to the active router go unanswered, the standby router becomes the active router and starts processing IP packets for the subnet.

Both routers are configured with standard IP addresses on their interface into the subnet. Each router also has a special virtual IP address which is the same on both routers, configured via standby commands under the specific interfaces.

Configuring the Routers

Given a standard 24-bit subnet, we can build the following:

  • Network:
  • Subnet Mask:
  • Default Gateway:

Physical IP Address

  • Building Router A:
  • Building Router B:

The configuration commands are as follows:

building router a#
interface fa0/2
ip address

This sets the IP address for the interface

standby 100 timers 3 10
100 denotes the HSRP process number as "hot standby group 100". You can have multiple HSRP standby groups on the same interface. The timers command sets the interval to 3 seconds between HELLO messages, and waits 10 seconds before the other router is declared down.
standby 100 priority 200 preempt

Defines the priority of this router. The highest priority number will win the election. "Preempt" allows the router to take over control even if there is not an election in process if it comes on line with the highest priority.

standby 100 authentication fnord

Optional - Authentication [word] creates an unencrypted authentication process for each HSRP packet.

standby 100 ip

Establishes as the virtual interface. This IP address should be the same on both HSRP routers.

standby 100 track fa0/0
This article was originally published on Aug 2, 2004
Get the Latest Scoop with Networking Update Newsletter