The script I want to use is the one below. The issues is finding a way to run pings from the device that I have connected to in the bash script.. The ssh is opened by running a script, and I don't have direct access to the ssh info. The script calls for me to put in my creds to connect. I appreciate any help.
#!/bin/bash
#Ol mnqnzf
echo "Enter the alarm ticket contents."
pluma Contents
cat Contents | grep -E -o "(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)" > ipfound
for IP in $(cat ipfound);
do
ping -c 5 $IP
echo ""
done
rm ipfound
rm Contents