Cisco Systems, Inc.(R)    Cisco | Profile | Contacts & Feedback | Help
Cisco SMB Support Assistant
Configure Hot Standby Routing Protocol on Cisco Routers
Home > Work With My Routers > Cisco Routers > Configure Hot Standby Routing Protocol on Cisco Routers  
 

Configure Hot Standby Routing Protocol on Cisco Routers



     Introduction
     Requirements
     HSRP and MHSRP Overview
          Configure HSRP
          Configure MHSRP
     Next Step
     Troubleshoot the Procedure
     Related Information



Introduction

This document explains how to configure Hot Standby Routing protocol (HSRP) and Multiple HSRP (MHSRP) on a Cisco router for redundancy and load balancing.


Back to Top



Requirements

To perform the steps described in this document, you need to have these items:


Back to Top



HSRP and MHSRP Overview

HSRP provides high network availability by providing redundancy for IP traffic from hosts on networks. HSRP routes IP traffic without relying on the availability of any single router. It enables a set of router interfaces to work together, to present the appearance of a single virtual router or default gateway to the hosts on a LAN. In a group of router interfaces, the active router is the router of choice for routing packets; the standby router is the router that takes over the routing duties when an active router fails. When HSRP is configured on a network segment, it provides a virtual MAC address and an IP address that is shared among router interfaces in a group of router interfaces running HSRP. The router selected by the protocol to be the active router receives and routes packets destined for the group's MAC address. HSRP detects when the designated active router fails, and a selected standby router assumes control of the group's MAC and IP addresses. A new standby router is also selected at that time. Devices running HSRP send and receive multicast UDP-based hello packets to detect router failure and to designate active and standby routers.

config_hot_standby_routers_01.gif

Multiple HSRP (MHSRP) is an extension of HSRP that allows load sharing between two or more HSRP groups in addition to provide redundancy. In a simple MHSRP configuration, two routers are configured to be part of two HSRP groups. However, the first router is the active router for first group and standby for the second group whereas, the second router is the active router for second group and standby for the first group. This is achieved by assigning a priority to each router for each group. During normal operation, the two routers share the IP traffic load. When either router becomes unavailable, the other router becomes active and assumes the packet-transfer functions of the router that is unavailable.

config_hot_standby_routers_02.gif

In this document two routers are connected to the inside network through interface fastEthernet0/0 via a switch. The fastEthernet0/0 interfaces of the routers are assigned IP addresses 192.168.10.1 and 192.168.10.2 respectively. The default gateway for the hosts in the inside network is the virtual IP address of HSRP/MHSRP and not the assigned IP addresses of the fastEthernet0/0 interface. For MHSRP, the first router is active router for group 1 and the second router is the active router for group 2.

Configure HSRP

Follow these steps to configure HSRP on a router:

  1. Connect to the console of the first router, refer Create a HyperTerminal Connection.

  2. Get into the interface configuration mode and configure the IP address for the interface.

    Router#configure terminal
    Enter configuration commands, one per line.  End with CNTL/Z.
    Router(config)#interface fastEthernet0/0
    Router(config-if)#ip address 192.168.10.1 255.255.255.0
    
  3. Enter the command standby ip followed by a virtual IP address to activate HSRP on the configured interface. Enter no shut command to bring up the interface.

    Router(config-if)#standby ip 192.168.10.3
    Router(config-if)#no shut
    
  4. Exit the configuration mode and return to exec mode. Save this configuration.

    Router(config-if)#end
    Router#copy running-config startup-config
    

    Configure the second router using the same steps and change the IP addresses to reflect the second router’s IP addresses but use the same virtual IP address in the standby ip command.

Configure MHSRP

Follow these steps to configure MHSRP on the first router:

  1. Connect to the console of the first router, refer Create a HyperTerminal Connection.

  2. Get into the interface configuration mode and configure the IP address for the interface.

    Router#configure terminal
    Enter configuration commands, one per line.  End with CNTL/Z.
    Router(config)#interface fastEthernet0/0
    Router(config-if)#ip address 192.168.10.1 255.255.255.0
    
  3. Enter the command standby ip with a group id followed by a virtual IP address to activate MHSRP on the configured interface. Also, assign a priority of a value above 100 to make the router active for this group using the command standby priority. Enter the standby preempt command so that the router becomes active for this group if it gets reloaded.

    Router(config-if)#standby 1 ip 192.168.10.3
    Router(config-if)#standby 1 priority 110
    Router(config-if)#standby 1 preempt
    
  4. To make this router standby for the other group enter the command standby ip with a different group id followed by a virtual IP address of the other group.

    Router(config-if)#standby 2 ip 192.168.10.4
    Router(config-if)#standby 2 preempt
    
  5. Enter no shut command to bring up the interface. Exit the configuration mode and return to exec mode. Save this configuration.

    Router(config-if)#no shut
    Router(config-if)#end
    Router#copy running-config startup-config
    

    Follow these steps to configure MHSRP on the second router:

  6. Connect to the console of the second router, refer Create a HyperTerminal Connection

  7. Get into the interface configuration mode and configure the IP address for the interface.

    Router#configure terminal
    Enter configuration commands, one per line.  End with CNTL/Z.
    Router(config)#interface fastEthernet0/0
    Router(config-if)#ip address 192.168.10.2 255.255.255.0
    
  8. Enter the command standby ip with a group id followed by a virtual IP address to activate MHSRP on the configured interface. Also, assign a priority of a value above 100 to make the router active for this group using the command standby priority. Enter the standby preempt command so that, the router becomes active for this group if it gets reloaded.

    Router(config-if)#standby 2 ip 192.168.10.4
    Router(config-if)#standby 2 priority 110
    Router(config-if)#standby 2 preempt
    
  9. To make this router standby for the other group, enter the command standby ip with a different group id followed by a virtual IP address of the other group.

    Router(config-if)#standby 1 ip 192.168.10.3
    Router(config-if)#standby 1 preempt
    
  10. Enter no shut command to bring up the interface. Exit the configuration mode and return to exec mode. Save this configuration.

    Router(config-if)#no shut
    Router(config-if)#end
    Router#copy running-config startup-config
    

Back to Top



Next Step

You have now configured HSRP on your router.

To make further changes to your router, refer to the Router Support Page.

To configure other devices in your network, refer to the Configuration Overview Page.


Back to Top



Troubleshoot the Procedure

This section provides information about common problems that you may encounter. If this information does not solve your problem, contact the SMB Technical Assistance Center (SMB TAC) for assistance.

Problem

Cause(s) and Suggested Solution(s)

Check if HSRP/MHSRP is working properly.

Use the command show standby and check the output if the virtual IP addresses are in use and the status is shown as active.


Back to Top



Related Information

Service Requests

  Open a service request
  Update a service request

Feedback

Please rate this site:
++ + +/- - --

Suggestions for improvement:




If Cisco may contact you for more details
or for future feedback opportunities,
please enter your contact information:

Full Name:
Email:



© 1992-2006 Cisco Systems, Inc. All rights reserved. Terms and Conditions, Privacy Statement, Cookie Policy and Trademarks of Cisco Systems, Inc.