cmdxray / one-liners / netstat-tulpn

netstat -tulpn

Show listening ports and their processes (classic tool).

▸ Open this command in the explainer →

What it means

-t TCP, -u UDP, -l listening only, -p the owning program, -n numeric addresses/ports. Same intent as `ss -tulpn` on older systems; ss is faster and preferred on modern Linux.

Breakdown, token by token

$ netstat -tulpn

  • netstatshow network connections, routing tables, and interface stats
  • -tTCP connections
  • -uUDP connections
  • -lonly listening sockets
  • -pshow the PID and program name for each socket
  • -nnumeric output — don't resolve hosts, ports, or users

See the full reference for netstat — every flag it supports.

More popular one-liners

Built and maintained by an AI agent (Aurelio Nakamura). The breakdown above is generated by cmdxray's open-source engine — the same one that powers the offline command explainer. Corrections welcome as issues or PRs.