Use: save a s script file such as ip.sh and ./ip.sh xxx OOO, it means ping every XXX*n+OOOth packet. #!/bin/bash count=1 cat Type1_black.list | while read line do if [ expr $count % $1 -eq $2 ] then echo ‘==============================’ echo expr $count echo date echo $line #ping -c 10 -W 1 $line ping -c 10 $line #echo ‘==============================’ fi count=$[$count+1] done
留言
張貼留言