Monday, May 7, 2018

bash loop

run.sh
#!/bin/sh
for ((c = 1; c < 1000; c++))
do
echo "running $c times"
/root/en.sh
sleep 60
/root/run_ping.sh
done

root@LCDV2-00084:/root# cat run_ping.sh
#!/bin/sh
ping -c 5 192.168.1.121

No comments:

Post a Comment