栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > 后端开发 > Java

出现Identify and stop the process that‘s listening on port 8080 or configure this application等解决方法

Java 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

出现Identify and stop the process that‘s listening on port 8080 or configure this application等解决方法

目录
  • 1. 问题所示
  • 2. 问题分析
  • 3. 解决方法
    • 3.1 关闭进程
    • 3.2 修改端口

1. 问题所示

出现如下问题:

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

Description:

Web server failed to start. Port 8080 was already in use.

Action:

Identify and stop the process that's listening on port 8080 or configure this application to listen on another port.


Process finished with exit code 1

截图如下:

2. 问题分析

通过查看相关错误日志,发现是端口被占用了
一种是清除8080被占用的端口,另一种解决方案是换一个端口(也可不用8080端口)

知道了解决方案之后就很好解决方法
具体解决方法如下

3. 解决方法

关闭进程或者修改端口号两种方法

3.1 关闭进程

通过netstat 8080,查看是否有进程在使用这个端口(但是列表中的内容比较多,不好查看比较)

精确查询应该配合findstr(注意命令应和linux区分开来,这是windows版本)
完整命令如下:netstat -ano | findstr 8080

杀死该进程即可:taskkill /F /PID 26868


重启服务即可成功

3.2 修改端口

既然端口号被占用,那就换一种思路,修改8080端口为你想要的(不占用其他端口)
操作如下:

增加内容如下:server.port= 8085

重启服务即可成功

额外补充:如果重启之后网页打开如下:

可看我之前的文章:
springboot出现Whitelabel Error Page This application has no explicit mapping for /error解决方案

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/988246.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号