手机
当前位置:查字典教程网 >脚本专栏 >linuxshell >检测网站down掉后自动发信的shell脚本代码
检测网站down掉后自动发信的shell脚本代码
摘要:复制代码代码如下:#!/bin/bash#websitetestscriptswhiletrue;doforcycle_tempin`cat...

复制代码 代码如下:

#!/bin/bash

#website test scripts

while true;do

for cycle_temp in `cat url_list`

do

if lynx -dump `echo ${cycle_temp}` -accept_all_cookies|grep "true";then

echo "The website is running naturally"

else

echo "${cycle_temp} has been offline please attend it now!">/opt/test.txt

mail -v -s "website down mail" reterry123@163.com < /opt/test.txt

fi

done

sleep 2s

done

【检测网站down掉后自动发信的shell脚本代码】相关文章:

linux中批量修改文件名的脚本代码

后台实时分流文件的shell脚本

防止ARP攻击的shell代码

linux下实现ftp自动备份shell脚本

备份网站内容的shell脚本代码

ssh expect自动登录的脚本代码

Linux下查找后门程序 CentOS 查后门程序的shell脚本

检查linux网络状态的两个脚本

shell遍历目录处理特定目录的脚本代码

并发数据库压力测试的shell脚本代码

精品推荐
分类导航