Thursday, April 2, 2009

Netstat for finding Out Applications Running on NIX box

Netstat is a handy tool which can also help out in finding Applications running on the box. Using netstat we can list down current listening sockets which infers to the applications running on the box.

$ netstat -alptn

-a, --all
-l, --listening
Show only listening sockets. (These are omitted by default.)
-p, --program
Show the PID and name of the program to which each socket belongs.
-n, --numeric
Show numerical addresses instead of trying to determine symbolic host, port or user names.
-t, --tcp
Limits the output to show only TCP connections

It can also be done using "nmap hostname/IP" but it is restricted sometimes due to security reasons.

No comments:

Post a Comment