ss sock监控抓取
作者:互联网
Falcon指标如下:
Zabbix实现方式:
[root@kvm-10-128-52-177 zabbix_agent2.d]# cat ss_socket.conf UserParameter=ss.estab,ss -s |grep estab|awk {'print $4'}|sed 's/,//g' UserParameter=ss.closed,ss -s |grep estab|awk {'print $6'}|sed 's/,//g' UserParameter=ss.orphaned,ss -s |grep estab|awk {'print $8'}|sed 's/,//g' UserParameter=ss.synrecv,ss -s |grep estab|awk {'print $10'}|sed 's/,//g' UserParameter=ss.timewait,ss -s |grep estab|awk {'print $12'}|awk -F"/" {'print $1'} UserParameter=ss.slabinfo.timewait,ss -s |grep estab|awk {'print $12'}|awk -F"/" {'print $2'}|sed 's/),//g'
标签:estab,ss,sock,抓取,UserParameter,awk,print,grep 来源: https://www.cnblogs.com/weidongliu/p/16190833.html