How to see what ports are open in my computer

To find out what ports are open or exposed, follow these steps:

Start >Run >type "cmd"
At the command line type "netstat -a > c:\portsStatus.txt" {enter)

This will create a file called portsStatus.txt in c: drive. Open this file, you will get the list of each ports in your computer. Interesting, eh ?

The list displayed shows "Listening ports" and established "Who is on the other end" connections to your computer.

Also,
Who is listening: netstat -an |find /i "listening"
Who is established: netstat -an |find /i "established"

Also, if yourcomputer's operating system is XP and want to see what are the open ports at this mements, then type:->
netstat -ao |find /i "listening"

This will give the detail against some Process Ids (PID)s.


Till now you have identified the list of ports that are in use at this moment. And somehow you smelled that one of the port is in use which really should not be (this may be due to any reason; for example - say tomcat was running on another system, but now the lan-wire is unplugged for your system). So, in such cases you may be curious to free up that port.
Really are you ....??
Well, run this command to see exactly which DLL and EXE files are using which ports:-
netstat -anobv
You must get output similar to:-

Once, you identify the EXE file; you can go to Task Manager -> Process and kill that process.

Enjoy your port now :D

Comments

Popular posts from this blog

Java

RTC - Repository : How to Revert Back the Changes