这是运行tomcat时经常会遇到的一个问题,提示8005,8080,8009端口被占
Several ports (8005, 8080, 8009) required by Tomcat v7.0 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).
解决方案如下
1.打开 cmd,输入 netstat -ano|findstr 8080
/查看当前端口的状态
当前状态为 :被占
2.输入 taskkill /pid 8044 /f 结束当前任务,释放端口
当前端口已经被关闭
注意,这个数值8004是PID值,也就是 上面查看状态时,最后的那个数字
此时,无需关闭eclipes,直接运行就好,可以看到很快就成功运行