问题描述:Error starting ApplicationContext. To display the conditions report re-run your application with ‘debug’ enabled.

或者:The Tomcat connector configured to listen on port 7001 failed to start. The port may already be in use or the connector may be misconfigured.

problems

解决方法:这类问题在springboot中经常出现,凡是类似的问题一般都是端口被占用了,找出占用端口的PID然后结束进程即可

  1. 打开cmd命令窗口 输入如下指令查看所有端口和PID
netstat -ano
  1. 可以直接输入要查找的端口号进行查找:
netstat -aon|findstr 7001

在这里插cmd入图片描述
3. 找到对应的端口对应的PID 输入指令找到对应的进程

 tasklist | findstr "2816"

find
4. 杀掉该进程 再次启动就OK啦

  taskkill /f /t /im java.exe 

kill

Logo

旨在为数千万中国开发者提供一个无缝且高效的云端环境,以支持学习、使用和贡献开源项目。

更多推荐