首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > JAVA > J2EE开发 >

tomcat启动时报错,该如何解决

2012-02-12 
tomcat启动时报错,急!2009-9-27 17:29:11 org.apache.catalina.core.AprLifecycleListener init信息: The

tomcat启动时报错,急!
2009-9-27 17:29:11 org.apache.catalina.core.AprLifecycleListener init
信息: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: D:\Program Files\Java\jdk1.6.0_10\jre\bin;D:\Program Files\apache-tomcat-6.0.14\bin
2009-9-27 17:29:11 org.apache.coyote.http11.Http11Protocol init
信息: Initializing Coyote HTTP/1.1 on http-8888
2009-9-27 17:29:11 org.apache.catalina.startup.Catalina load
信息: Initialization processed in 668 ms
2009-9-27 17:29:11 org.apache.catalina.core.StandardService start
信息: Starting service Catalina
2009-9-27 17:29:11 org.apache.catalina.core.StandardEngine start
信息: Starting Servlet Engine: Apache Tomcat/6.0.14
2009-9-27 17:29:12 org.apache.catalina.core.ApplicationContext log
信息: ContextListener: contextInitialized()
2009-9-27 17:29:12 org.apache.catalina.core.ApplicationContext log
信息: SessionListener: contextInitialized()
2009-9-27 17:29:13 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info
信息: Parsing configuration file [struts-default.xml]
2009-9-27 17:29:13 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info
信息: Unable to locate configuration files of the name struts-plugin.xml, skipping
2009-9-27 17:29:13 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info
信息: Parsing configuration file [struts-plugin.xml]
2009-9-27 17:29:13 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info
信息: Parsing configuration file [struts.xml]
2009-9-27 17:29:13 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info
信息: Loading global messages from message
2009-9-27 17:29:14 com.opensymphony.xwork2.util.logging.commons.CommonsLogger warn
警告: Unable to load config class com.test.interceptor.MyInterceptor at interceptor - file:/D:/Program%20Files/apache-tomcat-6.0.14/webapps/struts2/WEB-INF/classes/struts.xml:14:79 probably due to a missing jar, which might be fine if you never plan to use the myInterceptor interceptor
2009-9-27 17:29:14 com.opensymphony.xwork2.util.logging.commons.CommonsLogger error
严重: Actual exception
Caught Exception while registering Interceptor class com.test.interceptor.MyInterceptor - interceptor - file:/D:/Program%20Files/apache-tomcat-6.0.14/webapps/struts2/WEB-INF/classes/struts.xml:14:79
at org.apache.struts2.impl.StrutsObjectFactory.buildInterceptor(StrutsObjectFactory.java:77)
at com.opensymphony.xwork2.config.providers.InterceptorBuilder.constructInterceptorReference(InterceptorBuilder.java:59)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.lookupInterceptorReference(XmlConfigurationProvider.java:1092)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.buildInterceptorList(XmlConfigurationProvider.java:531)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addAction(XmlConfigurationProvider.java:369)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:460)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadPackages(XmlConfigurationProvider.java:265)
at org.apache.struts2.config.StrutsXmlConfigurationProvider.loadPackages(StrutsXmlConfigurationProvider.java:111)
at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:189)
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:55)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:360)
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:403)
at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:69)
at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:48)
at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:275)


at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)
at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:108)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3696)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4343)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920)
at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at org.apache.catalina.core.StandardService.start(StandardService.java:516)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:566)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Caused by: java.lang.ClassNotFoundException: com.test.interceptor.MyInterceptor
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1358)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1204)
at com.opensymphony.xwork2.util.ClassLoaderUtil.loadClass(ClassLoaderUtil.java:146)
at com.opensymphony.xwork2.ObjectFactory.getClassInstance(ObjectFactory.java:96)
at com.opensymphony.xwork2.ObjectFactory.buildBean(ObjectFactory.java:149)
at com.opensymphony.xwork2.ObjectFactory.buildBean(ObjectFactory.java:139)
at org.apache.struts2.impl.StrutsObjectFactory.buildInterceptor(StrutsObjectFactory.java:52)
... 40 more
2009-9-27 17:29:14 org.apache.coyote.http11.Http11Protocol start
信息: Starting Coyote HTTP/1.1 on http-8888
2009-9-27 17:29:14 org.apache.jk.common.ChannelSocket init
信息: JK: ajp13 listening on /0.0.0.0:8009
2009-9-27 17:29:14 org.apache.jk.server.JkMain start
信息: Jk running ID=0 time=0/46 config=null
2009-9-27 17:29:14 org.apache.catalina.startup.Catalina start
信息: Server startup in 3173 ms


[解决办法]
天呀~~~
这英文谁看得懂呀


不过只认识前面的关键代码
 D:\Program Files\Java\jdk1.6.0_10\jre\bin;D:\Program Files\apache-tomcat-6.0.14\bin 

可能是你包的问题吧
[解决办法]
什么原因?
[解决办法]
重新启动tomcat看一下
[解决办法]
jdk跟tomcat有冲突,tomcat6必须对应jdk1.6.不然就有异常!
[解决办法]
Caused by: java.lang.ClassNotFoundException: com.test.interceptor.MyInterceptor 




错误很明显,这个类不存在,原因你自己找去。
也许名字错了,也许真的不存在。
[解决办法]
tomcat6 必须要jdk6 才可以滴,报错是说你的JDK版本不对,找不到。你可以重新配置下JDK。。。
[解决办法]
看来新手比较多,还是老紫竹一针见血!
[解决办法]
2个原因:第一:tomact没有配置好

第二:

Unable to load config class com.test.interceptor.MyInterceptor at interceptor - file

看这句呀 就是你说的问题呀 delete就可以了

热点排行