欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

Spring启动遇到端口号被占用

程序员文章站 2022-05-30 21:19:53
...

遇到的问题,端口号8080被占用

Error starting ApplicationContext. To display the auto-configuration report re-run your application with 'debug' enabled.
2020-02-12 21:00:11.945 ERROR 13624 --- [           main] o.s.b.d.LoggingFailureAnalysisReporter   : 

***************************
APPLICATION FAILED TO START
***************************

Description:

The Tomcat connector configured to listen on port 8080 failed to start. The port may already be in use or the connector may be misconfigured.

Action:

Verify the connector's configuration, identify and stop any process that's listening on port 8080, or configure this application to listen on another port.

解决:

  1. 打开cmd
  2. 找到8080端口的PID:netstat -aon|findstr “8080”
    Spring启动遇到端口号被占用
  3. 杀死进程:taskkill /pid 4432 -f

Spring启动遇到端口号被占用
4. 查看进程
Spring启动遇到端口号被占用
5. 重新启动,启动成功。

相关标签: Java