Aliases: -a --all
, -A --protocol=
-c --continious
, -e --extend
, -g --groups
, -i --interface=
, -l --listening
, -M --masquerade
, -n --numeric
, -N --symbolic
, -o --timers
, -p --program
, -r --route
, -s --statistics
, -t --tcp
, -T --notrim
, -u --udb
, -v --verbose
, -w --raw
, -Z context
Shows both listening and non-listening sockets
Deprecated |
Replacement |
netstat -a |
ss -a |
Specifies the address families for which connections are to be shown. [family] is a comma separated list of address family keywords like inet
, unix
, ipx
, ax25
, netrom
, and ddp
. This has the same effect as using the --inet
, --unix
(-x
), --ipx
, --ax25
, --netrom
, and --ddp
options. ss
families: unix
, inet
, inet6
, link
, netlink
Deprecated |
Replacement |
netstat -A [family] |
ss -f [family] |
Configures netstat to refresh the displayed information every second until stopped.
Deprecated |
Replacement |
netstat -c |
Not apparent |
Prints routing information from the route cache.
Deprecated |
Replacement |
netstat -C |
ip r list cache |
Displays an increased level of detail.
Deprecated |
Replacement |
netstat -e |
ss -e |
Prints routing information from the forward information database (FIB).
Deprecated |
Replacement |
netstat -F |
Not apparent |
Displays multicast group membership information for IPv4 and IPv6.
Deprecated |
Replacement |
netstat -g |
ip ma , ip ma show [interface] |
Displays a table of all network interfaces, or the specified [name].
Deprecated |
Replacement |
netstat -i |
ip -s link |
Shows only listening sockets (which are omitted by netstat be default).
Deprecated |
Replacement |
netstat -l |
ss -l |
Displays a list of masqueraded connections (connections being altered by Network Address Translation).
Deprecated |
Replacement |
netstat -M |
Not apparent |
Show numerical addresses instead of trying to determine symbolic host, port or user names (skips DNS translation).
Deprecated |
Replacement |
netstat -n |
ss -n |
Shows numerical host addresses but does not affect the resolution of port or user names.
Deprecated |
Replacement |
netstat --numeric-hosts |
Not apparent |
Shows numerical port numbers but does not affect the resolution of host or user names.
Deprecated |
Replacement |
netstat --numeric ports |
Not apparent` |
Shows numerical user IDs but does not affect the resolution of host or port names.
Deprecated |
Replacement |
netstat --numeric-users |
Not apparent |
Displays the symbolic host, port, or user names instead of numerical representations. Netstat does this by default.
Deprecated |
Replacement |
netstat -N |
ss -r |
Includes information related to networking timers.
Deprecated |
Replacement |
netstat -o |
ss -o |
Shows the process ID (PID) and name of the program to which each socket belongs.
Deprecated |
Replacement |
netstat -p |
ss -p |
Shows the kernel routing tables.
Deprecated |
Replacement |
netstat -r |
ip r , ip r show all |
Displays summary statistics for each protocol.
Deprecated |
Replacement |
netstat -s |
ss -s |
Filters results to display TCP only.
Deprecated |
Replacement |
netstat -t |
ss -t |
Stops trimming long addresses.
Deprecated |
Replacement |
netstat -T |
Not apparent |
Filters results to display UDP only.
Deprecated |
Replacement |
netstat -u |
ss -u |
Produces verbose output.
Deprecated |
Replacement |
netstat -v |
Not apparent |
Filter results to display raw sockets only.
Deprecated |
Replacement |
netstat -w |
ss -w |
Prints the SELinux context if SELinux is enabled. On hosts running SELinux, all processes and files are labeled in a way that represents security-relevant information. This information is called the SELinux context.
Deprecated |
Replacement |
netstat -Z |
Not apparent |