How to find a list of sockets held by a process in windows? How to find a list of sockets held by a process in windows? windows windows

How to find a list of sockets held by a process in windows?


Type netstat -a -o -n -b from an elevated (admin) command prompt.

-b is to display the executable involved in creating each connection or listening port. See netstat --help for a list of all options.


I like TCPView from SysInternals: http://technet.microsoft.com/en-us/sysinternals/bb897437Good for lots of other things too, but to check your own process out, just find it in the list and look at the sockets it has open, addresses they are bound to, etc. You can also watch the dynamic pattern of your processes socket usage.