Step one, Windows view all ports
Click Start in the lower left corner of the computer, then select the Run option, and then in the popup window, enter the "cmd" command to make the command prompt. Then we enter "Netstat-ano" in the window and press ENTER, which will show all the port usage. :
Step two, query the specified port occupancy
In the window, continue to enter the "Netstat-aon|findstr" Prompt Port "", for example, the prompt port is 2080, then the input command is "NETSTAT-AON|FINDSTR" 2080 "", enter after you can see the list of PID, Then, according to the PID in the computer's Task Manager to view the corresponding appropriation program, and then to close.
Step three, query PID corresponding to the process
If, after the above steps, we get a PID of 2016, then we can enter the command "TASKLIST|FINDSTR" 2016 ", in the first line to display the name is the program name, so we understand that the program occupies the port.
Step four, then we enter the command "taskkill/f/t/im program name" can be.
Windows common Commands--view port processes