Skip to content

Instantly share code, notes, and snippets.

@abdallah
Created November 7, 2011 08:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abdallah/1344452 to your computer and use it in GitHub Desktop.
Save abdallah/1344452 to your computer and use it in GitHub Desktop.
Netstat to to find number of connections from each IP
netstat -anp |grep 'tcp\|udp' | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n
# found @ http://midnight-cafe.co.uk/linux-commands/netstat-to-find-number-of-connections-from-each-ip/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment