IDEA在调试程序的时候出现:
Error running 'LocalTest': Address localhost:8080 is already in use以及
Error running 'LocalTest': Unable to open debugger port (127.0.0.1:56999): java.net.SocketException "Interrupted function call: accept failed"
使用如下方案解决:
1.管理员身份运行CMD
2.在CMD中使用如下命令:
netstat -ano|findstr 8080
找出占用你程序端口的程序(我的程序使用的是8080端口,根据你程序部署时候设置的值,将8080修改为对应的):
3.可以看到,8080端口被pid为4188的程序占用了,根据PID将其杀掉:
taskkill -pid 4188 –f