Skip to content

Instantly share code, notes, and snippets.

@hattmarris
Last active September 13, 2015 01:26
Show Gist options
  • Save hattmarris/1415e466d617b1bc411b to your computer and use it in GitHub Desktop.
Save hattmarris/1415e466d617b1bc411b to your computer and use it in GitHub Desktop.
netstat
# netstat
$ netstat -tulpn # [--tcp|-t] [--udp|-u] [--listening|-l] [--numeric|-n] [--program|-p]
# Active Internet connections (only servers)
# Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
# tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 22535/mysqld
# tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 16902/sshd
# tcp6 0 0 :::80 :::* LISTEN 4969/apache2
# tcp6 0 0 :::22 :::* LISTEN 16902/sshd
# udp 0 0 0.0.0.0:15213 0.0.0.0:* 580/dhclient
# udp 0 0 0.0.0.0:68 0.0.0.0:* 580/dhclient
# udp6 0 0 :::10071 :::* 580/dhclient
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment