netstat -ant
ss -ant
lsof -i:80
nethogs
yum install nload iptraf nethogs -y
查网卡实时总流量
nload -m
nload - displays the current network usage
查每进程占用的流量
nethogs - Net top tool grouping bandwidth per process
查每个ip占用流量
ethtool eth0
参考: 较成熟的脚本 https://www.centos.bz/2014/06/shell-script-for-network-analysis/