Skip to content

Latest commit

 

History

History
82 lines (54 loc) · 1.65 KB

netstat.md

File metadata and controls

82 lines (54 loc) · 1.65 KB
title date icon background tags categories intro
Netstat
2021-01-27 03:44:21 -0800
icon-netstat
bg-slate-700
network
utility
port
Linux Command
This quick reference cheat sheet provides various for using netstat command.

Getting started {.cols-3}

Statistics

All connections on port 80

$ netstat -anp | grep :80

Netstat Help

$ netstat -h

Listening

Option Example
netstat -ltunp All Listening ports
netstat -ltn Listening TCP ports
netstat -lun Listening UDP ports
netstat -lx Listening Unix ports

Connections

Option Example
netstat -a All connections
netstat -at All TCP connections
netstat -au All UDP connections

Statistics

Option Example
netstat -s Display statistics
netstat -st Display TCP statistics
netstat -su Display UDP statistics

Networks

Option Example
netstat -i Show network interfaces
netstat -ie Show network interfaces extended info

Routing

Option Example
netstat -r Show routing table
netstat -rn Show routing table, don't resolve hosts