org.apache.catalina.LifecycleException: Failed to stop component(生命周期异常)

时间:2022-10-31 16:01:02


真是郁闷透顶,以前昨天还可以用,换了myeclipse自带的tomcat就可以用:

异常:

org.apache.catalina.LifecycleException: Failed to stop component(生命周期异常)



org.apache.catalina.LifecycleException: Failed to stop component [org.apache.catalina.webresources.StandardRoot@34ccd6d9]
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:233)
at org.apache.catalina.core.StandardContext.resourcesStop(StandardContext.java:4995)
at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5576)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:221)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:259)
at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:860)
at org.apache.catalina.core.ContainerBase.destroyInternal(ContainerBase.java:1040)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:860)
at org.apache.catalina.core.ContainerBase.destroyInternal(ContainerBase.java:1040)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.StandardService.destroyInternal(StandardService.java:604)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.StandardServer.destroyInternal(StandardServer.java:879)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.startup.Catalina.start(Catalina.java:634)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:351)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:485)
Caused by: org.apache.catalina.LifecycleException: An invalid Lifecycle transition was attempted ([before_stop]) for component [org.apache.catalina.webresources.DirResourceSet@370736d9] in state [INITIALIZED]
at org.apache.catalina.util.LifecycleBase.invalidTransition(LifecycleBase.java:395)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:208)
at org.apache.catalina.webresources.StandardRoot.stopInternal(StandardRoot.java:759)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:221)
... 21 more
十二月 13, 2017 7:24:34 下午 org.apache.catalina.util.LifecycleBase destroy
警告: Calling stop() on failed component [org.apache.catalina.webresources.StandardRoot@34ccd6d9] to trigger clean-up did not complete.
org.apache.catalina.LifecycleException: Failed to stop component [org.apache.catalina.webresources.StandardRoot@34ccd6d9]
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:233)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:259)
at org.apache.catalina.core.StandardContext.destroyInternal(StandardContext.java:5655)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:860)
at org.apache.catalina.core.ContainerBase.destroyInternal(ContainerBase.java:1040)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:860)
at org.apache.catalina.core.ContainerBase.destroyInternal(ContainerBase.java:1040)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.StandardService.destroyInternal(StandardService.java:604)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.core.StandardServer.destroyInternal(StandardServer.java:879)
at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)
at org.apache.catalina.startup.Catalina.start(Catalina.java:634)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:351)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:485)
Caused by: org.apache.catalina.LifecycleException: An invalid Lifecycle transition was attempted ([before_stop]) for component [org.apache.catalina.webresources.DirResourceSet@370736d9] in state [INITIALIZED]
at org.apache.catalina.util.LifecycleBase.invalidTransition(LifecycleBase.java:395)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:208)
at org.apache.catalina.webresources.StandardRoot.stopInternal(StandardRoot.java:759)
at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:221)
... 20 more



 

解决方法(我把原先的tomcat给删除了,重新配置tomcat就ok,特别需要注意的是tomcat里面一定要是纯净的,我是直接在官网上下载的tomcat):

org.apache.catalina.LifecycleException: Failed to stop component(生命周期异常)