This document describes how to configure a standby Hot Standby Router Protocol (HSRP) for IPv6 (HSRPv2) group to track an object and change the HSRP priority on the basis of the object state.
Each tracked object has a unique number that is specified on the tracking command-line interface (CLI). HSRPv2 uses this number to track a specific object. The tracking process periodically polls the tracked object for value changes and sends any changes (as up or down values) to HSRPv2, either immediately or after a specified delay. This document uses the track interface command in order to configure an interface to be tracked.
Ensure that you meet these requirements before you attempt this configuration:
Knowledge of configuring HSRP; refer to Configuring HSRP for more information.
Basic knowledge of implementing IPv6 addressing and basic connectivity; refer to Implementing IPv6 Addressing and Basic Connectivity for more information.
Basic knowledge of Enhanced Object Tracking
HSRPv2 must be enabled on an interface before HSRP IPv6 can be configured.
IPv6 unicast routing must be enabled on the device for HSRP IPv6 to be configured.
The configurations in this document are based on the Cisco7200 series router that runs Cisco IOS® Software Release 15.0(1).
Refer to Cisco Technical Tips Conventions for information on document conventions.
The R2 and R3 routers are connected to R1 via a serial interface. The Fast Ethernet interfaces of R2 and R3 are configured with HSRP IPv6 in such a way that R2 acts as the active router and R3 acts as the standby router. In router R2, the tracking process is configured to track the state of the interface line protocol of serial interface 1/0: In case the serial interface S1/0 of R2 goes down, the R3 router changes its state from Standby to Active.
Note: Use the Command Lookup Tool (registered customers only) to find more information on the commands used in this document.
This document uses this network setup:
This document uses these configurations:
Router R1 Configuration |
---|
! version 15.0 ! hostname R1 ! ipv6 unicast-routing ipv6 cef ! ! interface Serial1/0 no ip address ipv6 address 2010:10:10:10::1/64 serial restart-delay 0 ! ! interface Serial1/1 no ip address ipv6 address 2011:11:11:11::1/64 serial restart-delay 0 ! end |
Router R2 Configuration |
---|
! version 15.0 ! hostname R2 ! ipv6 unicast-routing ipv6 cef ! track 1 interface Serial1/0 line-protocol !--- Tracking process 1 is configured in the router !--- to track state of the interface line protocol !--- of serial interface 1/0 ! interface Serial1/0 no ip address ipv6 address 2010:10:10:10::2/64 serial restart-delay 0 ! ! interface FastEthernet2/0 no ip address duplex auto speed auto ipv6 address 1010:1:1:1::10/64 standby version 2 standby 10 ipv6 autoconfig !--- Assigns a standby group and standby IP address. standby 10 preempt delay minimum 45 !--- The preempt command allows the router to become the !--- active router when it has the priority higher than all the other !--- HSRP-configured routers. Without this command, even if a router has higher !--- priority value, it will not become an active router. !--- The delay minimum value causes the local router to postpone !--- taking over the active role for a minimum of 45 seconds. standby 10 track 1 decrement 10 !--- Configures HSRP to track an object and change the Hot Standby !--- priority on the basis of the state of the object. !--- In this example,the HSRP tracks the interface s1/0 mentioned !--- in the track process 1. !--- Decrement value specified the amount by which the Hot Standby !--- priority for the router is decremented (or incremented) when the tracked object !--- goes down (or comes back up). The range is from 1 to 255. The default is 10. ! end |
Router R3 Configuration |
---|
! version 15.0 ! hostname R3 ! ipv6 unicast-routing ipv6 cef ! interface Serial1/0 no ip address ipv6 address 2011:11:11:11::2/64 serial restart-delay 0 ! interface FastEthernet2/0 no ip address duplex auto speed auto ipv6 address 1010:1:1:1::11/64 standby version 2 standby 10 ipv6 autoconfig standby 10 priority 95 standby 10 preempt delay minimum 45 ! end |
Use the show standby command on the R2 and R3 routers in order to verify the configuration.
Router R2 |
---|
R2#show standby FastEthernet2/0 - Group 10 (version 2) State is Active 5 state changes, last state change 00:26:03 Virtual IP address is FE80::5:73FF:FEA0:A Active virtual MAC address is 0005.73a0.000a Local virtual MAC address is 0005.73a0.000a (v2 IPv6 default) Hello time 3 sec, hold time 10 sec Next hello sent in 1.872 secs Preemption enabled, delay min 45 secs Active router is local Standby router is FE80::C802:AFF:FE10:38, priority 95 (expires in 8.048 sec) Priority 100 (default 100) Track object 1 state Up decrement 10 Group name is "hsrp-Fa2/0-10" (default) |
Router R3 |
---|
R3#show standby FastEthernet2/0 - Group 10 (version 2) State is Standby 4 state changes, last state change 00:26:25 Virtual IP address is FE80::5:73FF:FEA0:A Active virtual MAC address is 0005.73a0.000a Local virtual MAC address is 0005.73a0.000a (v2 IPv6 default) Hello time 3 sec, hold time 10 sec Next hello sent in 0.176 secs Preemption enabled, delay min 45 secs Active router is FE80::C801:14FF:FEF4:38, priority 100 (expires in 9.888 sec) MAC address is ca01.14f4.0038 Standby router is local Priority 95 (configured 95) Group name is "hsrp-Fa2/0-10" (default) |
In order to display tracking information, use the show track command in router R2.
Router R2 |
---|
R2#show track 1 Track 1 Interface Serial1/0 line-protocol Line protocol is Up 3 changes, last change 00:28:39 Tracked by: HSRP FastEthernet2/0 10 !--- Displays the information about the objects that !--- are tracked by tracking process 1. R2#show track int brief Track Object Parameter Value Last Change 1 interface Serial1/0 line-protocol Up 00:31:19 !--- Displays the information about the tracked interface. |
In case the active router (R2 in this example) goes down, the standby router changes its state immediately to Active as shown in this table:
When the active router (R2) goes down... |
---|
Router R2 R2(config)#interface s1/0 R2(config-if)#shut R2(config-if)# *May 21 20:56:54.223: %TRACKING-5-STATE: 1 interface Se1/0 line-protocol Up->Down R2(config-if)# *May 21 20:56:56.203: %LINK-5-CHANGED: Interface Serial1/0, changed state to administratively down *May 21 20:56:57.203: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial1/0, changed state to down R2(config-if)# *May 21 20:57:43.087: %HSRP-5-STATECHANGE: FastEthernet2/0 Grp 10 state Active -> Speak R2(config-if)# *May 21 20:57:54.479: %HSRP-5-STATECHANGE: FastEthernet2/0 Grp 10 state Speak -> Standby !--- When the interface goes down, the active router changes !--- its state to Standby.Router R3 R3# *May 21 20:56:53.419: %HSRP-5-STATECHANGE: FastEthernet2/0 Grp 10 state Standby-> Active !--- The standby router is now the active router. R3#show standby FastEthernet2/0 - Group 10 (version 2) State is Active 5 state changes, last state change 00:02:32 Virtual IP address is FE80::5:73FF:FEA0:A Active virtual MAC address is 0005.73a0.000a Local virtual MAC address is 0005.73a0.000a (v2 IPv6 default) Hello time 3 sec, hold time 10 sec Next hello sent in 0.080 secs Preemption enabled, delay min 45 secs Active router is local Standby router is FE80::C801:14FF:FEF4:38, priority 90 (expires in 9.664 sec) Priority 95 (configured 95) Group name is "hsrp-Fa2/0-10" (default) |
There is currently no specific troubleshooting information available for this configuration.
Revision | Publish Date | Comments |
---|---|---|
1.0 |
22-May-2012 |
Initial Release |