Port occupied problem in web project

When the project is started, we often see that the port is occupied. At this time, there are two solutions: one is to change the port of the project configuration file; the other is to release the occupied port.

Let's look at the second type here. To release the occupied port requires two commands:

netstat -ano|findstr Occupied port number
taskkill /t /f /im TCP number corresponding to occupied port number The
specific steps are as follows:

(1) Open the cmd command window and enter the netstat -ano|findstr XXXX command to query the TCP number corresponding to the port;

Insert picture description here

Above, the occupied port number is 7777, and the corresponding TCP number of this port is 13100;

(2) Enter taskkill /t /f /im XXXX command to turn off the occupied port.

Insert picture description here

Guess you like

Origin blog.csdn.net/weixin_44192389/article/details/109320784