linux 检测ddos 攻击的命令
# netstat -anp |grep ‘tcp\|udp’ | awk ‘{print $5}’ | cut -d: -f1 | sort | uniq -c | sort -n
# netstat -ntu | awk ‘{print $5}’ | cut -d: -f1 | sort | uniq -c | sort -nr
# netstat -ntu | grep -v TIME_WAIT | awk ‘{print $5}’ | cut -d: -f1 | sort | uniq -c | sort -nr
# netstat -an | grep :80 | awk ‘{print $5}’ | cut -f1 -d”:” | sort | uniq -c | sort -n