Tomcat启动报错Several ports (8005, 8080, 8009)

今天启动Tomcat的时候发现报错了

Tomcat启动报错Several ports (8005, 8080, 8009)

Several ports (8005, 8080, 8009) required by Tomcat v5.5 Server at localhost are already in use. The server may already be running in another process, or a system process may be using the port. To start this server you will need to stop the other process or change the port number(s).

原因:端口8005, 8080, 8009被占用了。可能是在打开Tomcat的情况下关闭了Eclipse,或是Eclipse非正常关闭,导致先前的Tomcat没有被关闭,端口占用。或是其他软件占用了tomcat的端口号。

我的解决方案:

干掉占用端口的软件。

Win + R  cmd

输入netstat   -anonetstat -an | grep 8080 命令  就可以看到哪个进程占用了8080和8009端口,找到占用端口软件的PID,然后在任务管理器找到对应PID的软件,关闭结束该进程即可。

Tomcat启动报错Several ports (8005, 8080, 8009)

如果任务管理器中没有显示PID列,需要设置,查看 →  选择列 → 勾选PID。

Tomcat启动报错Several ports (8005, 8080, 8009)

找到之后  干掉它  重新启动  问题解决。