Solved FreeBSD's netstat usage

  • Thread starter Thread starter Sensucht94
  • Start date Start date
S

Sensucht94

Guest
Hi, I'm asking a very stupid question here, but i didn't mange to find a solution myself, so please bare with me

how to list all opened/forwarded ports, with associated running daemon and PID, potentially established connection and relative IPs?

I mean, the equivalent of a nestat -ant in GNU's net-tools port applied to FreeBSD's netstat(1)

Thank you
 
I believe -a and -n work the same way. Replace -t with -p tcp (for protocol == TCP/IP) or maybe -4.

awesome, thanks, I had missed the -p switch in man page. Meanwhile I've also discovered sockstat(1): a sockstat -l4 practically does exactly what I was looking for ;)
 
Back
Top