What Network Port is that Service using?

When considering network port numbers, the numbers are divided into three ranges: the Well Known ports, the Registered ports and the Dynamic (Private) ports.  The Internet Assigned Numbers Authority (IANA) is responsible for the global coordination of the port assignments.  The Well Known port range is from 0 – 1023, Registered ports run from 1024 […]

When considering network port numbers, the numbers are divided into three ranges: the Well Known ports, the Registered ports and the Dynamic (Private) ports.  The Internet Assigned Numbers Authority (IANA) is responsible for the global coordination of the port assignments.  The Well Known port range is from 0 – 1023, Registered ports run from 1024 – 49151, and the Dynamic ports run from 49152 – 65535.

So how do we determine the port that a service is using?  Without using Network Monitor, Wireshark or a similar utility, there are a couple of very handy utilities provided with the operating system that we can use – NETSTAT.EXE and TASKLIST.EXE.  Most administrators are familiar with NETSTAT.EXE already, but for those who are not, you can use NETSTAT.EXE to identify what ports are being used by a particular process.  The syntax that we will be using for NETSTAT.EXE is as follows: netstat.exe –a –n –o.  The switches we are using provide the following:

Full Article

Additional Resources: