HSRP configuration command directory

debug standby 

show standby

standby authentication

standby ip

standby mac-address

standby priority, standby preempt

standby timers

standby track

 

debug standby

  Use "debug standby" command to show hsrp runtime infomation .Use "no debug standby" to stop showing the information.

debug standby [interface interface-name group-id] event

no debug standby [interface interface-name group-id] event

 

Parameter:

none

 

Command mode:

manage model

 

Explanation:

output all hsrp group runtime event information configured in the interface. if you want to appoint one hsrp group, the corresponding interface name and group id must be supplied .

 

Example:

debug standby output information show below :

Router# debug standby event

2000-1-13 00:00:09 HSRP EVT : e0/0 group 0 delete virtual ip 192.168.20.1
2000-1-13 00:00:09 HSRP EVT : e0/0 group 0 add virtual ip 192.168.20.5

 

debug standby [interface interface-name] [group-id] packets

no debug standby [interface interface-name] [group-id] packets

 

Parameter:

none

 

Command mode:

manage model

 

Explanation:

Show HSRP interactive packet information, such as sending HSRP packet, receiving HSRP response etc… . If you want to appoint one hsrp group, the corresponding interface name and group id must be supplied .

 

Example:

Router# debug standby packets

 

2000-1-13 00:08:57 HSRP PKT SEND : e0/0 HELLO out 192.168.20.237 Active pri 100 ip 192.168.20.201
2000-1-13 00:09:00 HSRP PKT SEND : e0/0 HELLO out 192.168.20.237 Active pri 100 ip 192.168.20.201

field

description

2001-1-13 00:08:57

processing hsrp packet time

HSRP PKT

HSRP Packet

SEND/RECV

Send/Recv HSRP Packet

e0/0

interface name recv/send packet

HELLO/COUP/RESIGN

packet type

192.168.20.237

ip packet source address

Active/Standby/Speak

hsrp protocol status

pri 100

hsrp group priority

ip 192.168.20.201

hsrp gourp virtual ip address

 

debug standby [interface interface-name] [group-id] errors

no debug standby [interface interface-name] [group-id] errors

 

Parameter:

none

 

Command mode:

manage model

 

Explanation:

Show HSRP interactive error information. If you want to appoint one HSRP group, the corresponding interface name and group id must be supplied .

 

debug standby [interface interface-name] [group-id] terses

no debug standby [interface interface-name] [group-id] terses

 

Parameter:

none

 

Command mode:

manage model

 

Explanation:

Show HSRP interactive terse information. If you want to appoint one HSRP group, the corresponding interface name and group id must be supplied .

 

show standby

Use "show standby" command to show HSRP group status infomation .

show standby [interface interface-name

 

Parameter:

interface-name : interface name to show hsrp gourp information

 

Default:

show all hsrp group information in every interface

Command mode:

manage/config/interface config model

 

Explanation:

Show HSRP group information. If you want to appoint one HSRP group, the corresponding interface name and group id must be supplied .

 

Example:

Router# show  standby interface e0/0

       Ethernet0/0 - Group 0
          HSRP State is Active
          Virtual IP address : 192.168.20.201/24 (config)
          Virtual Mac address : 0000.0102.0306
          Active Router IP : 192.168.20.237
          Standby Router IP : unknown
          Preempt is not set
          Current Priority is 100
          Config Priority is 100
          HSRP timer : hello 3 s(default) hold 10s (default)
          HSRP current timer : hello 3 active 3 standby 0
          Authentication string is aaaaaaaa

Domain

Description

Ethernet0/0

interface name

Group 0

HSRP Group id

HSRP State is Acvite

HSRP Group status is Active

 Virtual IP address : 192.168.20.201/24 (config)

HSRP Group virtual ip is 192.168.20.201(configure by command)

Virtual Mac address : 0000.0102.0306

virtual mac address is 0000.0102.0306

Active Router IP : 192.168.20.237

Active Router ip address is 192.168.20.237

Standby Router IP : unknown

Standby Router ip address is unknown

 Preempt is not set

not config preempt

Current Priority is 100

current priority level is 100

Config Priority is 100

configured priority level is 100

HSRP timer : hello 3 s(default) hold 10s (default)

hello timer is 3s(default), hold timer is 10s(default)

Authentication string is D-Link

authentication string is D-Link

 

show standby brief

 

Parameter:

nonr

 

Command mode:

supevisor mode/global configuration mode/interface configuration mode

 

Explanation:

show hsrp group brief information 

 

Example:

Router# show  standby brief

Interface Grp Prio Pree State  Active addr    Standby addr Virtual addr
         e0/0          0   100  N    Active 192.168.20.237 unknown      192.168.20.201

domain

description

Interface

interface name

Grp

HSRP Group id

Prio

priority

Pree

preempt

State

current hsrp group status

Active addr

current hsrp group active router address

Standby addr

current hsrp group standby router address

Virtual addr

current hsrp group virtual ip address

 

standby authentication 

Use "standby authentication"  command to configure hsrp group authentication string . Use "no standby authentication" to configure default authentication string .

standby [group-number] authentication string
no standby [group-number] authentication

 

Parameter:

Group-number

(Optional)hsrp group id

String

 authentication string . default string is "D-Link"

 

Default:

group-number: 0
string: D-Link

 

Command mode:

interface configure mode

 

Explanation:

  Authentication string in all hsrp packet transfered is unencrypted.The same authentication string must be configured in one hsrp group of every router and access server to interact.HSRP group virtual ip address and timer can not be learned from other router if authentication unmatched .But authentication string unmatched can not deny one router to be replaced by another router .

 

Example:

    hsrp group 1 of interface ethernet0/0 is configured authentication string "word" :

interface ethernet 0/0

standby 1 authentication word

 

standby ip

Use "standby ip" command to enable hsrp protocol process .Use "no standby ip" to disable hsrp protocol process .

standby [group-number] ip [ip-address [secondary]]
no standby [group-number] ip [ip-address]

 

Parameter:

group-number

(Optional)hsrp group id to enable

ip-address

(Optional)hsrp group virtual ip

Secondary

(Optional)hsrp group virtual secondary ip

 

Default:

group-number: 0
hsrp protocl is disabled.

 

Command mode:

interface configure mode

 

Explanation:

"standby ip"  enable HSRP protocol process .If ip address is supplied,the ip address act as the hsrp group virtual ip address .If not supplied,hsrp group should learn virtual ip address from active router.Virtual ip address must be configured in one hsrp router at least of a hsrp group.

If hsrp process is enabled , proxy ARP process shouled be change unless proxy arp is disabled.If hsrp group status is active,proxy ARP request should be replied by hsrp group virtual mac-address . Otherwise ,proxy ARP is disabled .

 

Example:

   configure a hsrp group 1 in ehternet 0/0 . the hsrp group virtual ip should be learned from active router .

interface ethernet 0/0

standby 1 ip

 

   the three virtual ip address used the same virtual mac address in arp table.

ip address 1.1.1.1. 255.255.255.0

ip address 1.2.2.2. 255.255.255.0 secondary

ip address 1.3.3.3. 255.255.255.0 secondary

ip address 1.4.4.4. 255.255.255.0 secondary

standby ip 1.1.1.254

standby ip 1.2.2.254 secondary

standby ip 1.3.3.254 secondary

 

standby mac-address

Use "standby ip" command to configure hsrp group virtual mac-address .Use "no standby ip" to configure default virtual mac-address.

standby [group-number] mac-address mac-address
no standby [group-number] mac-address

 

Parameter:

Group-number

(Optional)hsrp group id

mac-address

the virtual mac address to configure

 

Default:

group-number: 0
mac-address: 0x00 00 0c 07 ac group-number

 

Command mode:

interface configure mode

 

Explanation:

     HSRP group default virtual mac address is "0x00 00 0c 07 ac group-numer"

 

Example:

    HSRP group 1 virtual mac-address is 0x00 00 01 02 03 04

interface ethernet 0

standby 1 authentication 00:00:01:02:03:04

 

standby priority, standby preempt

Use "standby priority" command to configure hsrp group priority level .Use "no standby priority" to configure default standby priority level .

   Use "standby preempt" command to configure hsrp group preempt and delay timer .Use "no standby preempt" to configure default standby preempt and delay timer .

 

standby [group-number] priority priority
standby [group-number] preempt [delay delay]

no standby [group-number] priority
no standby [group-number] preempt

 

Parameter:

group-number

(Optional)HSRP Group id

Priority priority

(Optional)priority level(1-255), default value is 100

Preempt

(Optional)If router is configued preempt,it should coup the active router while the priority level is larger than it.Otherwise ,the local router act as active until no other router is active .

delay delay

(Optional) Delay Parameter appoint the delay timer which local router replace the active router .Scope is from 0 to 3600 seconds .Default value is 0〔no delay〕.

 

Default:

group-number:     0
priority:            100
delay:
                0 seconds( no delay) .

 

Command mode:

interface configure mode

 

Explanation:

  Configure priority value to select active and standby router.If preempt is configured ,the router with largest priority value is active .If priority is equal,the router with higher ip address is active .   

  Warning: If standby track is configured and the track interface is invalid,the group priority can be changed dynamic .

  While the router reboot, the route table is not a whole .If the preempt is configured ,the router maybe act as an active without the full route service.This problem can be resolved by configure a delay timer .

 

Example:

 router priority level is 120(larger than default value ) and delay 300 seconds(5 minutes) before acting as a active router :

interface ethernet 0

standby ip 172.19.108.254

standby priority 120 preempt delay 300


 

standby timers

Use "standby timer" command to configure hsrp group timer  .Use "no standby timer" to configure default standby timer.

standby [group-number] timers hellotime holdtime
no standby [group-number] timers

 

Parameter:

group-number

(Optional)group id

Hellotime

hello timer (1-255) seconds

Holdtime

hold timer (1-255) seconds

Default:

group-number: 0
hellotime: 3 seconds
holdtime: 10 seconds

 

Command mode:

interface configure mode

 

Explanation:

Use "standby timers" command to configure hsrp hello packet sending interval and standing interval used to judge the active/standby router invalid .

If the hello/hold timer is not configured , hsrp group can be learned from active router and access server .Generally,hold timer is larger of equal 3 times hellotime.

 

Example:

  A hsrp group 1 is configured in interface e0/0. The hello timer (hello packet sending interval) is 5 seconds ,the hold timer is 15 seconds  :

interface ethernet 0/0

standby 1 ip

standby 1 timers 5 15

standby track

Use "standby track" command to enable hsrp group priority level track other interface status change .Use "no standby track" to disable the track.

standby [group-number] track interface interface-name [interface-priority]

no standby [group-number] track interface interface-name [interface-priority]

 

Parameter:

group-number

(Optional)group id

interface-name

track interface name

Interface-priority

(可选)delta value of tracking interface

Default:

group-number: 0
interface-priority: 10

 

Command mode:

interface configure model

 

Explanation:

   The command contact hsrp group priority with interface status .

   If the track interface is failed, the hsrp group priority decrease a delta value (defaul 10).If the interface is not tracked, the priority value do not change .

   Optional Parameter interface-priority appoint the delta value while the tracking interface is failed or up.If the tracking interface changed from failed to up , the delta value is add to priority ,Otherwise decrease.

 

 Example:

    Two tracking interface (e0/0 and s0/0) is configured in hsrp group 0 in interface e1/1 .If e0/0 or s0/0 is failed , the hsrp group priority should be decreased 10(default value)

interface ethernet 1/1

ip address 198.92.72.37 255.255.255.240

no ip redirects

standby track ethernet 0/0

standby track serial 0/0

standby preempt

standby ip 198.92.72.46