查看系统当前处于连接状态(tcpCurrEstab)的连接数的方法

cat /proc/net/tcp |awk ‘{print $4}’|grep -c 01

当然也可以:
netstat -nat |grep -c ESTABLISHED

或者:
netstat -s -t | grep connections\ established

经过time测试,netstat -s -t | grep connections\ established 这种方法是效率最高的。

On this day..

Tags: ,

Leave a comment