Linux port occupied solve

1 Centos

The port number is assumed that occupied 8080

The first step, first check which port is occupied by a process.
To get occupied process PID, enter the command:

netstat -lnp|grep 8080

Here Insert Picture Description
The second step, use the command:

ps 28328 // 28328为占用进程PID

View a process which is occupied.
Here Insert Picture Description
The third step, use the command

kill -9 28328 // 28328为占用进程PID

Kill the process.

Guess you like

Origin blog.csdn.net/HW140701/article/details/91959783