Monitor device connection to the internet (CISCO)
PROBLEM: Monitor device access to the internet and create action when connection is not available (e.g. restart device).
SOLUTION: Creating IP SLA (monitor) and trigger e.g. ‘reload’ action using event manager (EEM).
[?] What is IP SLA?
https://learningnetwork.cisco.com/blogs/vip-perspectives/2017/06/13/ip-sla-fundamentals
//Create simple IP SLA with google DNS server as the target from interface FastEtheret 0/1
1 2 3 4 5 6 7 8 9 |
Router(config)# ip sla 1 Router(config-ip-sla)# icmp-echo 8.8.8.8 source-interface FastEthernet 0/1 Router(config-ip-sla)# timeout 5000 Router(config-ip-sla)# frequency 50 <strong>#Config IP sla to start now and live forever</strong> Router(config)# ip sla schedule 1 start-time now life forever <strong>#Track IP sla reachability</strong> track 10 rtr 1 reachability <strong>#On some other versions you have to use "track 1 ip sla 1 reachability"</strong> |
OUTPUT
1 |
*Sep 15 13:37:00 %TRACK-6-STATE: 10 ip sla 1 srate Up -> Down |
Copy & Paste
1 2 3 4 5 6 7 8 9 |
conf t ip sla 1 icmp-echo 8.8.8.8 source-interface FastEthernet 0/1 timeout 5000 frequency 50 exit ip sla schedule 1 start-time now life forever track 10 rtr 1 reachability exit |