We will configure the SLA tracking for R2 with the condition as R2 should be master unless ping response time to 126.96.36.199 exceeds 80 MS.
So we have configured the R2 with our above requirement:
track 2 rtr 1 ! ip sla monitor 1 type echo protocol ipIcmpEcho 188.8.131.52 threshold 80 int f1/0 vrrp 1 ip 184.108.40.206 vrrp 1 priority 105 vrrp 1 track 2
We got below messages once above configuration done.
*Sep 20 22:18:20.107: %SYS-5-CONFIG_I: Configured from console by conso *Sep 20 22:18:22.287: %VRRP-6-STATECHANGE: Fa1/0 Grp 1 state Master -> Backup
Checking the ping response:
R2#ping 220.127.116.11 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 18.104.22.168, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 8/9/12 ms
So now we enable the SLA tracking and observe what happens?
R2(config)#ip sla monitor schedule 1 start-time now R2(config)# *Sep 20 22:20:04.883: %VRRP-6-STATECHANGE: Fa1/0 Grp 1 state Backup -> Master R2(config)#
So now finally our R2 is master because MS time is below 80, if it exceeds above 80 then R2 will loose its master role and again will fall in backup sate.
Thanks for visiting…………….