tldr/pages/linux/netstat.md

28 lines
397 B
Markdown
Raw Normal View History

2014-09-11 11:38:56 +01:00
# netstat
> Displays various networks related information such as open connections, open socket ports etc.
2014-09-11 11:38:56 +01:00
- List all ports:
2014-09-11 11:38:56 +01:00
`netstat -a`
- List all listening ports:
2014-09-11 11:38:56 +01:00
`netstat -l`
- List listening TCP ports:
2014-09-11 11:38:56 +01:00
`netstat -t`
2014-09-11 11:38:56 +01:00
- Display PID and program names:
2014-09-11 11:38:56 +01:00
`netstat -p`
2014-09-11 11:38:56 +01:00
- List information continuously:
2014-09-11 11:38:56 +01:00
`netstat -c`
2016-01-14 13:52:25 +00:00
2016-01-14 14:26:38 +00:00
- List routes (-r) without resolving ip to hostname (-n):
2016-01-14 13:52:25 +00:00
2016-01-14 14:25:17 +00:00
`netstat -rn`