The server cannot be started because one or more of the ports are invalid. Open the server editor and correct the invalid ports.

在eclipse里运行jsp文件最初迟迟没有反应,重启报了这个错误,tomcat的端口设置有问题。需要打开服务器设置一下端口号。

 点击Servers,如果没有这一项,按照Window-Show View-Other...-Server-Servers调出。然后双击服务器(Tomcat)弹出编辑窗口。

在Modify the server ports栏里

Tomcat admin port 如果是-,就改为8005。Ctrl+s保存。再次运行解决了。

原文地址:https://www.cnblogs.com/8023spz/p/12378127.html