Show open ports (LISTEN)

lsof

lsof -Pni4 | grep LISTEN | column -t
click the source code to copy install lsof on any operating system with command-not-found.com