Last Updated: February 25, 2016
·
964
· hdragomir

Port to Process Mapping

When you want to know who's listening on a specific port, just use this:

lsof -i -P | grep -i "listen"

This will give you the name and PID of the processes as well as the ports they are bound to.

1 Response
Add your response

If you want to know who's listening on a specific port, that's an extremely inefficient approach. Better would be

lsof -i tcp:80
over 1 year ago ·