1 #!/bin/bash
2 echo `date +%Y-%m-%d-%H:%M:%S`start wget hanguo index.html >>/root/test.log
3 wget 112.175.*.*~/
4 size=`echo $?`
5 if [ "$size" -ne 0 ];then
6 echo "http error" | mail -s "hanguo 53 http error " 1550759257*@163.com
7 echo `date +%Y-%m-%d-%H:%M:%S`down wget hanguo index.hstm error >>/root/test.log
8 else
9 echo `date +%Y-%m-%d-%H:%M:%S`down wget hanguo index.html ok >>/root/test.log
10 fi
11 rm -rf ~/*.htm*
~
转载于:https://blog.51cto.com/15507592570/1612286