Find out which applications are listening to which port on Mac OSX

September 11th, 2009 by nils

If you ever wonder which ports are open on your OS X machine, or whether e.g. jboss is still running, this command will help you:

$sudo lsof -Pi | grep -i "listen"

FAQ: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/FAQ
Man page: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_man

2 Comments

  1. This one works nice as well :)

    lsof -i tcp:8080

    Comment by Scott Soleas — December 28, 2010 @ 9:01 am

  2. That one is much better actually :) Thanks for sharing Scott!

    Comment by nils — December 28, 2010 @ 9:31 pm

RSS feed for comments on this post.

Sorry, the comment form is closed at this time.