标签:链路检测
[root@va3 zabbix_agentd.d]# cat pingyz.conf UserParameter=ping.time[*],bash /etc/zabbix/shell/pingyztime.sh $1 UserParameter=ping.loss[*],bash /etc/zabbix/shell/pingyzloss.sh $1 [root@va3 zabbix_agentd.d]# cat ../shell/ cut-log.sh iosstatus.sh nginx_status.sh ping2.sh ping4.sh pingyzloss.sh processstatus2.sh ssh_scan.sh tcp_status.sh hour_nginx.sh mysqlstatus.sh ping1.sh ping3.sh ping.sh pingyztime.sh processstatus.sh ssh_scan.sh_ubuntu zabbix.sh [root@va3 zabbix_agentd.d]# cat ../shell/pingyz pingyzloss.sh pingyztime.sh [root@va3 zabbix_agentd.d]# cat ../shell/pingyz pingyzloss.sh pingyztime.sh [root@va3 zabbix_agentd.d]# cat ../shell/pingyzloss.sh resultloss=`ping -i 0.2 $1 -c 10 -w 3 |grep loss|awk -F ‘[ %]+‘ ‘{print $6}‘` echo ${resultloss} [root@va3 zabbix_agentd.d]# cat ../shell/pingyztime.sh resulttime=`ping $1 -c 1 |grep icmp_seq|awk -F ‘[=m]‘ ‘{print $7}‘` echo ${resulttime} [root@va3 zabbix_agentd.d]#
本文出自 “砖家博客” 博客,请务必保留此出处http://wsxxsl.blog.51cto.com/9085838/1911206
标签:链路检测
原文地址:http://wsxxsl.blog.51cto.com/9085838/1911206