diff --git a/测试该网站存活的ip有哪些.txt b/测试该网站存活的ip有哪些.txt new file mode 100644 index 0000000..ce635a1 --- /dev/null +++ b/测试该网站存活的ip有哪些.txt @@ -0,0 +1,15 @@ +#!/usr/bin/bash +# +#by fuxiaoshun 4/2 +ip=1.92.66 +for i in {1..10} +do + +ping -c1 $ip &>/dev/null +if [ $? -eq 0 ];then + echo "$ip.$i通" >>/tmp/up.txt + else + echo "$ip.$i不通" >>/tmp/down.txt +fi + +done \ No newline at end of file