Netstat CHEAT SHEET

This quick reference cheat sheet provides various for using netstat command.

networkutilityport
1
Sections
6
Cards

#Getting Started

Statistics

All connections on port 80

$ netstat -anp | grep :80

Netstat Help

$ netstat -h
Listening
OptionExample
netstat -ltunpAll Listening ports
netstat -ltnListening TCP ports
netstat -lunListening UDP ports
netstat -lxListening Unix ports
Connections
OptionExample
netstat -aAll connections
netstat -atAll TCP connections
netstat -auAll UDP connections
Statistics
OptionExample
netstat -sDisplay statistics
netstat -stDisplay TCP statistics
netstat -suDisplay UDP statistics
Networks
OptionExample
netstat -iShow network interfaces
netstat -ieShow network interfaces extended info
Routing
OptionExample
netstat -rShow routing table
netstat -rnShow routing table, don't resolve hosts