command ss
SS command :
ss is used to dump socket statistics. It allows showing information similar to netstat. It can display more TCP and state informations than other tools.
USAGE EXAMPLES
ss -t -a
Display all TCP sockets.
ss -t -a -Z
Display all TCP sockets with process SELinux security contexts.
ss -u -a
Display all UDP sockets.
ss -o state established '( dport = :ssh or sport = :ssh )'
Display all established ssh connections.
ss -x src /tmp/.X11-unix/*
Find all local processes connected to X server.
ss -o state fin-wait-1 '( sport = :http or sport = :https )' dst 193.233.7/24
List all the tcp sockets in state FIN-WAIT-1 for our apache to network 193.233.7/24 and look at their
timers.