Cisco HSRP Tracking

HSRP Tracking is pretty easy to do. You have several options as you’ll see below.

INTERFACE LINE PROTOCOL STATE
—–Tracks whether the specified interface is up or down (line protocol state is up/down)

track 1 interface FastEthernet0/X/0 line-protocol

interface Gig0/0
standby 1 ip x.x.x.x
standby 1 priority 105  (Higher is better.  Default is 100)
standby 1 preempt
standby 1 track 1 decrement 10

INTERFACE IP ROUTING STATE
—–Track whether the specified interface is UP, has an IP Address, and has IP Routing enabled

track 1 interface fastEthernet 0/X/0 ip routing

interface Gig0/0
standby 1 ip x.x.x.x
standby 1 priority 105  (Higher is better.  Default is 100)
standby 1 preempt
standby 1 track 1 decrement 10

IP ROUTE REACHABILITY
—–Tracks whether an IPv4 route exists and is reachable from the local device

track 1 ip route 172.16.200.0/24 reachability  

interface Gig0/0
standby 1 ip x.x.x.x
standby 1 priority 105  (Higher is better.  Default is 100)
standby 1 preempt
standby 1 track 1 decrement 10

PING NEXT HOP SELF
—–Tracks whether the next hop (ISP) is up

ip sla 1
icmp-echo x.x.x.x source-interface FastEthernet0/X/0
frequency 5

ip sla schedule 1 life forever start-time now

track 1 ip sla 1 reachability

interface Gig0/0
standby 1 ip x.x.x.x
standby 1 priority 105  (Higher is better.  Default is 100)
standby 1 preempt
standby 1 track 1 decrement 10