HSRP
HSRP
5.WHAT IS HSRP?
--it is a cisco proprietary protocol which allows more than one router to use
single IP address for a particular network for providing gateway redundancy
--it allows only one router as an active and others are as standby mode
--the active router is responsible for forwarding the traffic and if it fails then
only the standby router takes the responsibility of active router for forwarding
the traffic
--in every 3 sec routers exchange hello messages to get the update
--hold down time is 10 sec-after 10 sec hsrp declares the gateway is down so that
standby be active and forward the lan traffic
R1
R1(config)#int f0/0
R1(config-if)#no shut
R1(config-if)#ip add 192.168.1.100 255.255.255.0
R1(config-if)#exi
R1(config)#int s0/0
R1(config-if)#no shut
R1(config-if)#ip add 11.1.1.1 255.0.0.0
R1(config-if)#clock rate 64000
R1(config-if)#exit
R1(config)#exit
R1#sh ip int brief
R2
R2(config)#int f0/0
R2(config-if)#no shut
R2(config-if)#ip add 192.168.1.200 255.255.255.0
R2(config-if)#exi
R2(config)#int s0/0
R2(config-if)#no shut
R2(config-if)#ip add 12.1.1.2 255.0.0.0
R2(config-if)#exit
R2(config)#exit
R2#sh ip int brief
R3
R3(config)#int f0/0
R3(config-if)#no shut
R3(config-if)#ip add 13.1.1.1 255.0.0.0
R3(config-if)#exi
R3(config)#int s0/0
R3(config-if)#no shut
R3(config-if)#ip add 11.1.1.2 255.0.0.0
R3(config-if)#exit
R3(config)#int s0/1
R3(config-if)#no shut
R3(config-if)#ip add 12.1.1.1 255.0.0.0
R3(config-if)#clock rate 64000
R3(config-if)#exit
R3(config)#exit
R3#sh ip int brief
ii)configure routing
a)configure default routing on both R1 AND R2
R1
R1(config)#=ip route 0.0.0.0 0.0.0.0 11.1.1.2
R2
R2(config)#=ip route 0.0.0.0 0.0.0.0 12.1.1.1
iii)configure hsrp
R1
R1(config)#int f0/0
R1(config-if)#standby 2 ip 192.168.1.10
R1#sh standby
FastEthernet0/0 - Group 2
State is Active
4 state changes, last state change 00:29:50
Virtual IP address is 192.168.1.10
Active virtual MAC address is 0000.0C07.AC02
Local virtual MAC address is 0000.0C07.AC02 (v1 default)
Hello time 3 sec, hold time 10 sec
Next hello sent in 1.25 secs
Preemption disabled
Active router is local
Standby router is unknown
Priority 100 (default 100)
Group name is hsrp-Fa0/0-2 (default)
CONFIGURE PREEMT
R1(config-if)#standby 2 priority <value>
R1(config-if)#standby 2 preempt
R1(config-if)#standby 2 timers <hello> <hold down>
R2
R2(config)#int f0/0
R2(config-if)#standby 2 ip 192.168.1.10
R2#
%HSRP-6-STATECHANGE: FastEthernet0/0 Grp 2 state Speak -> Standby
R2#sh standby
FastEthernet0/0 - Group 2
State is Standby
3 state changes, last state change 00:32:08
Virtual IP address is 192.168.1.10
Active virtual MAC address is 0000.0C07.AC02
Local virtual MAC address is 0000.0C07.AC02 (v1 default)
Hello time 3 sec, hold time 10 sec
Next hello sent in 1.728 secs
Preemption disabled
Active router is 192.168.1.100
Standby router is local
Priority 100 (default 100)
Group name is hsrp-Fa0/0-2 (default
R1(config-if)#shut
%HSRP-6-STATECHANGE: FastEthernet0/0 Grp 2 state Active -> Init
R2#
%HSRP-6-STATECHANGE: FastEthernet0/0 Grp 2 state Standby -> Active
verification command
r#show standby
r#sh standby brief