Difference between revisions of "Netstat"

From DevOps Notebook
(Created page with "=== Get connections per IP sorted === <syntaxhighlight lang="bash"> # netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n </syntaxhighlight>")
 
 
Line 1: Line 1:
 
=== Get connections per IP sorted ===
 
=== Get connections per IP sorted ===
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
# netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n
+
netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n
 
</syntaxhighlight>
 
</syntaxhighlight>

Latest revision as of 10:56, 25 July 2024

Get connections per IP sorted

netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n