09-26-2024 01:56 PM
Hi Guys,
is anyone able to help me write a event manager script to extract all of the IP addresses from the arp cache and then ping them in turn
something like this pseudo code
event manager applet Check_ARP_and_Ping
event timer cron cron-entry "*/1 * * * *"
action 1.0 cli command "enable"
action 2.0 cli command "show ip arp vrf IOT"
action 3.0 regexp "COLLECT THE IP ADDRESSES from the above output" in $ip_list
action 4.0 foreach ip "$ip_list"
action 4.1 cli command "ping vrf IOT $ip_list repeat 2"
action 5.0 end
09-27-2024 05:22 AM
Just curious, why?
10-02-2024 01:23 AM
Hi Joseph,
it is part of an SDA deployment where I have trouble with silent hosts dropping off the network, these pesky devices wont respond to broadcast pings either of 255.255.255.255 so I need to check what's online and then keep it talking.
I have wrote a python script from a centralised machine that will SSH into the switch and perform the ARP capture and subsequent ping commands but it I think it would be neat to do it all on the box via eem.
also I cannot use the built in docker as I'm using it for something else
10-02-2024 03:39 AM
Hosts also will not respond to a subnet broadcast?
10-04-2024 12:16 AM
correct..... they wont respond to the subnet broadcast either, it seems the network cards they use in these IOT devices are not developed very well
10-04-2024 04:11 AM
As a possible alternative approach, how about the possibly of just sequentially pinging all the IPs that these IoT devices might use? Although this approach will ping unused IPs, it probably would be an easier EEM script.
BTW this question might also get better EEM help within the Network Management topic.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide