0

即使我从 WEBAPPS 目录中删除所有应用程序,Tomcat 也无法启动,而一切都像安装操作系统后一样。

日志(catalina.out)说:

Using CATALINA_BASE:   /usr/share/tomcat5
Using CATALINA_HOME:   /usr/share/tomcat5
Using CATALINA_TMPDIR: /usr/share/tomcat5/temp
Using JRE_HOME:       
Created MBeanServer with ID: -dpv07y:fl4s82vl.0:hydrogenium.timberlinecolorado.com:1
java.lang.NoClassDefFoundError: org.apache.catalina.core.StandardService
   at java.lang.Class.initializeClass(libgcj.so.7rh)
   at java.lang.Class.initializeClass(libgcj.so.7rh)
   at java.lang.Class.initializeClass(libgcj.so.7rh)
   at java.lang.Class.newInstance(libgcj.so.7rh)
   at org.apache.catalina.startup.Bootstrap.init(bootstrap.jar.so)
   at org.apache.catalina.startup.Bootstrap.main(bootstrap.jar.so)
Caused by: java.lang.ClassNotFoundException: org.apache.commons.modeler.Registry not found in org.apache.catalina.loader.StandardClassLoader{urls=[file:/var/lib/tomcat5/server/classes/,file:/usr/share/java/tomcat5/catalina-cluster-5.5.23.jar,file:/usr/share/java/tomcat5/catalina-storeconfig-5.5.23.jar,file:/usr/share/java/tomcat5/catalina-optional-5.5.23.jar,file:/usr/share/java/tomcat5/tomcat-coyote-5.5.23.jar,file:/usr/share/java/tomcat5/tomcat-jkstatus-ant-5.5.23.jar,file:/usr/share/java/tomcat5/tomcat-ajp-5.5.23.jar,file:/usr/share/java/tomcat5/servlets-default-5.5.23.jar,file:/usr/share/java/tomcat5/servlets-invoker-5.5.23.jar,file:/usr/share/java/tomcat5/catalina-ant-jmx-5.5.23.jar,file:/usr/share/java/tomcat5/tomcat-http-5.5.23.jar,file:/usr/share/java/tomcat5/tomcat-util-5.5.23.jar,file:/usr/share/java/tomcat5/tomcat-apr-5.5.23.jar,file:/usr/share/eclipse/plugins/org.eclipse.jdt.core_3.2.1.v_677_R32x.jar,file:/usr/share/java/tomcat5/servlets-webdav-5.5.23.jar,file:/usr/share/java/tomcat5/catalina-5.5.23.jar], parent=org.apache.catalina.loader.StandardClassLoader{urls=[file:/var/lib/tomcat5/common/classes/,file:/var/lib/tomcat5/common/i18n/tomcat-i18n-ja.jar,file:/var/lib/tomcat5/common/i18n/tomcat-i18n-fr.jar,file:/var/lib/tomcat5/common/i18n/tomcat-i18n-en.jar,file:/var/lib/tomcat5/common/i18n/tomcat-i18n-es.jar,file:/usr/share/java/tomcat5/naming-resources-5.5.23.jar,file:/usr/share/eclipse/plugins/org.eclipse.jdt.core_3.2.1.v_677_R32x.jar,file:/usr/share/java/tomcat5/naming-factory-5.5.23.jar], parent=gnu.gcj.runtime.SystemClassLoader{urls=[file:/usr/lib/jvm/java/lib/tools.jar,file:/usr/share/tomcat5/bin/bootstrap.jar,file:/usr/share/tomcat5/bin/commons-logging-api.jar,file:/usr/share/java/mx4j/mx4j-impl.jar,file:/usr/share/java/mx4j/mx4j-jmx.jar], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}}}
   at java.net.URLClassLoader.findClass(libgcj.so.7rh)
   at java.lang.ClassLoader.loadClass(libgcj.so.7rh)
   at java.lang.ClassLoader.loadClass(libgcj.so.7rh)
   at java.lang.Class.initializeClass(libgcj.so.7rh)
   ...5 more
4

4 回答 4

1

似乎您已经实现了 JMX 服务并尝试将其安装在 server.xml 文件中,但忘记将 apache commons modeler jar 添加到 server/lib 目录(因此为ClassNotFoundExceptionfor org.apache.commons.modeler.Registry)。检查您的 server.xml 文件是否有您可能添加的任何内容,并尝试将正确的 jar 文件添加到您的服务器类路径中。

于 2008-09-15T17:21:52.037 回答
0

似乎您需要将 commons-modeler 的 jar 放入$CATALINA_HOME/common/lib. 如果您没有将驱动程序的 jar 文件放入 tomcat 的服务器类路径,则在尝试设置 JDBC 数据源时会出现相同类型的错误。

于 2008-12-11T09:20:32.677 回答
0

对我来说,这尖叫着班级路径问题。你的tomcat到底安装在哪里?(给我们主目录在哪里的命令行打印输出。)另外,你是如何启动它的?

于 2008-09-15T12:48:05.410 回答
0

检查您的JAVA_HOME/JRE_HOME设置。您可能希望使用不同的 JVM,而不是随操作系统安装的 JVM

于 2008-09-15T12:56:33.423 回答