草庐IT

java - Spring Tool Suite - Pivotal tc Server Developer Edition v3.0 所需的8080端口已被占用

coder 2024-03-05 原文

在 Spring Tool Suite 中运行代码时出现以下错误。

..................................................... .....................................

Pivotal tc Server Developer Edition v3.0 所需的端口 8080 已被使用。服务器可能已经在另一个进程中运行,或者系统进程可能正在使用该端口。要启动此服务器,您需要停止其他进程或更改端口号。

..................................................... .....................................

下面是错误的截图。

另外,下面是我在 localhost:8080 上得到的

通过更改 server.xml 中的端口号(即 <Connector acceptCount="100" connectionTimeout="20000" executor="tomcatThreadPool" maxKeepAliveRequests="15" port="${bio.https.port}" protocol="org.apache.coyote.http11.Http11Protocol" redirectPort="${bio.https.port}"/> ),我得到了不同端口号的相同错误。

最佳答案

您有一个在 8080 上运行的应用程序,因此您需要终止当前在 8080 端口上运行的任何程序。

如果您运行的是 Windows,请使用:

netstat -a -o | find "8080"

如果您运行的是 Mac 操作系统(我认为您是),请使用:

sudo lsof -i :8080

终止该应用程序,然后启动 Pivotal。

否则,您可以在配置文件中更改关键服务器端口:

<your tc server folder location>/conf/catalina.properties

希望对您有所帮助。

关于java - Spring Tool Suite - Pivotal tc Server Developer Edition v3.0 所需的8080端口已被占用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27174981/

有关java - Spring Tool Suite - Pivotal tc Server Developer Edition v3.0 所需的8080端口已被占用的更多相关文章

随机推荐