tomcat Could not find or load main class org.apache.catalina.startup.Bootstrap

在网上搜索这个错误时,都是说 jdk版本低的问题。


 在官网下载apache-tomcat-7.0.22.tar.gz包:(1)当从下“Source Code Distributions”载包时,会遇到在bin目录下找不到bootstarp.jar的问题,“startup.sh”后显示

[root@ncut apache-tomcat-7.0.22]# bin/startup.sh
Using CATALINA_BASE:   /home/ncut/software/apache-tomcat-7.0.22
Using CATALINA_HOME:   /home/ncut/software/apache-tomcat-7.0.22
Using CATALINA_TMPDIR: /home/ncut/software/apache-tomcat-7.0.22/temp
Using JRE_HOME:        /usr/java/jdk1.6.0_26
Using CLASSPATH:       /home/ncut/software/apache-tomcat-7.0.22/bin/bootstrap.jar:/home/ncut/software/apache-tomcat-7.0.22/bin/tomcat-juli.jar

但是 ps -ef | grep tomcat  并没有启动.

(2)应该从“Binary Distributions“的下载core包,重新解压启动,查看端口和在浏览器输入http://localhost:8080/一切正常。

总结:下载安装包要正确。


你可能感兴趣的:(centOS,tomcat,centos,Bootstrap)