SEVERE: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/datasvc]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1245)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1895)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
Caused by: java.lang.IllegalStateException: Unable to complete the scan for annotations for web application [/datasvc] due to a StackOverflowError. Possible root causes include a too low setting for -Xss and illegal cyclic inheritance dependencies. The class hierarchy being processed was [org.bouncycastle.asn1.ASN1EncodableVector->org.bouncycastle.asn1.DEREncodableVector->org.bouncycastle.asn1.ASN1EncodableVector]
at org.apache.catalina.startup.ContextConfig.checkHandlesTypes(ContextConfig.java:2126)
at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2072)
at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1947)
at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1913)
at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1898)
at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1330)
at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:889)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:386)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5380)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 11 more
鍥涙湀 08, 2015 2:44:07 涓嬪崍 org.apache.catalina.startup.HostConfig deployDirectory
SEVERE: Error deploying web application directory /opt/tomcat-datasvc/webapps/datasvc
java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/datasvc]]
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:904)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1245)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1895)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
之前使用tomcat7时遇到启动报错问题,日志如下:
严重: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/mypro]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1114)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1673)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.IllegalStateException: Unable to complete the scan for annotations for web application [/mypro]. Possible root causes include a too low setting for -Xss and illegal cyclic inheritance dependencies
at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2109)
at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1981)
at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1947)
at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1932)
at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1326)
at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:878)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:369)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5179)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 11 more
Caused by: java.lang.StackOverflowError
at java.util.HashMap.get(HashMap.java:300)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2257)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
……
在网上找了很久,最终解决问题,在这时MARK一下。以下是解决方法:
--------------------------------------------------以下文章为转载--------------------------------------------------
使用tomcat 7.0.3x版本的同学可以发现tomcat启动慢了不少,而且还可能遇到如下启动时异常:
Unable to complete the scan for annotations for web application [] due to a StackOverflowError. Possible root causes include a too low setting for -Xss and illegal cyclic inheritance dependencies.
tomcat7.0.3X版本支持servlet3.0的特性,比如说支持@WebServlet、@WebListener,要支持这些特 性,tomcat就得去扫描所有的jar包里面的每个类。这个异常表明在扫描jar包的时候,递归调用太深,导致栈溢出了,tomcat给了一个馊主意, 让你增大xss,这个还是不好,xss加大了,可用线程数就少了。
分析tomcat源代码,发现它扫描的流程如下:
1.扫描所有jar包
2.通过查找jar包中META-INF/services/javax.servlet.ServletContainerInitializer文件内的定义,初始化ServletContainerInitializer实现
3.如果web.xml中配置了metadata-complete="true" 或者没有找到ServletContainerInitializer实现,都不会继续扫描jar包
网上大多数的答案的都是说在web.xml中加入了metadata-complete="true"就能避免这个异常。确实在很多场景下,这个 异常是能够避免。但是使用spring-web-3.1.0.RELEASE的同学就杯具了,这个jar包中定义了一个 ServletContainerInitializer,还是导致了扫描jar包。
我们可以用另外的办法来解决这个问题,我们让tomcat不扫描指定的jar包,tomcat就要轻松得多 了,org.apache.tomcat.util.scan.StandardJarScanner中定义了defaultJarsToSkip,有了 这个东东,我们就可以跳过某些jar包。
如果你不想使用servlet3.0 annotation支持,在tomcat的catalina.properties配置文件中 tomcat.util.scan.DefaultJarScanner.jarsToSkip的值后面加一个",*",这样就不会扫描所有的jar包 了。启动更快,也不会出异常。
tomcat在处理扫描是还有个小bug,比如我遇到了
SEVERE: Unable to process Jar entry [__MACOSX/cn/****/._HandlerFactory.class] from...
这是tomcat在扫描到以.class为后缀的文件后,就分析类,很明显,此文件都不是java类文件。tomcat不应该只判断后缀为.class就是java类文件。
相关推荐
严重 [RMI TCP Connection(3)-127.0.0.1] org.apache.catalina.core.StandardContext.startInternal Error-附件资源
标题 "chart_instrument_severe.rar" 提示我们这是一个与图表工具或严重情况有关的压缩文件,而实际上,根据描述,这个文件可能是一个网络聊天工具的服务器端实现,类似腾讯公司的聊天应用。考虑到标签 "site:...
24-Dec-2018 13:30:02.664 信息 [main] org.apache.catalina.startup.Catalina.startServer startup in 68664ms ``` 这一行日志表明Tomcat服务器在2018年12月24日13点30分02秒664毫秒时启动完成,耗时68664毫秒。...
log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost]=DEBUG, R log4j.logger.org.apache.catalina.core=debug, R log4j.logger.org.apache.catalina.session=debug, R ``` 这将使得Tomcat...
十二月 02, 2013 8:19:43 上午 org.apache.catalina.loader.WebappClassLoader clearReferencesJdbc SEVERE: The web application [/xxx] registered the JDBC driver [org.logicalcobwebs.proxool.ProxoolDriver] ...
“severe” 意为“严厉的”,符合对孩子的教育态度建议。 13. 题目:His eyes _______ with rage but he did not dare to say anything. 答案:A. flashed 解析:他的眼睛因愤怒而闪烁,但他不敢说什么。...
然而,在配置和运行Tomcat时,开发者常常会遇到各种问题,其中“`The required Server component failed to start so Tomcat is unable to start`”是一个常见的错误提示,这通常意味着Tomcat在启动过程中遇到了问题...
24-Feb-2018 10:15:07.213 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.listenerStop Exception sending context destroyed event to listener instance of class ...
- `org.apache.catalina.core.ContainerBase.[engine_name].[host_name].[context_name]`是用于特定容器的日志配置。 - `org.apache.catalina.core.AprLifecycleListener`、`org.apache.coyote.AbstractProtocol`...
- severe:严厉的老师出国了,你可以再次自由呼吸 - theory:关于月亮的一个理论是它是从地球上断裂的一部分 - rejected:我们拒绝了他关于建立音乐俱乐部的想法,决定改为艺术俱乐部 - linked:这两个城镇由...
forrtl: severe (38): error during write, unit 0, file CONOUT$ ArcGIS 10.2.2运行中出错; forrtl severe (38) error during write 都涉及到这样一个共同与下面DLL文件有关的arcgis visual Fortran runtime ...
- "From the very start":从一开始 - "Mean for sb. to do sth.":打算让某人做某事 - "Shut out":排除在外 - "Distracting thought":分心的想法 - "Push ... beyond one’s limits":把...推到极限 - ...
例如:The hot, humid (潮湿的) air over the ocean causes severe 49 thunderstorms. 在这道题中,我们可以通过分析词汇的后缀和前缀来确定空格的词性是形容词。 4. 副词的判断:在文章中,我们可以通过分析词汇...
9. severe - 马丁在交通事故中受了重伤,形容词 "severe"。 第三页提到了抽水的动作: 10. pumping - 正忙于从河里抽水到田里,现在分词 "pumping"。 第四页开始关注词形变化: 1. infect - 动词 "infect" 的...
1. "In recent days, we have to face the problem of pollution, which has become increasingly severe." 2. "To tackle this issue, we could implement recycling programs and encourage green living." 三、...
此外,对于形近词辨析,考生需要特别留意拼写相似但意义迥异的词,比如题目中提到的peculiar(特殊的)、particular(挑剔的)、specific(具体的),以及violent(猛烈的)、severe(严厉的)、extreme(极端的)、...
25. severe:严重的,形容词,常用于描述病情、天气或问题的严重程度。 26. clue:线索,名词,用于解决问题或寻找答案的关键信息。 27. pump:泵,n. 泵设备;vt. 用泵抽送,指液体或气体的传输工具。 28. ...
知识点8:With modern offices being more mechanized, designers are attempting to personalize them with warmer, less severe interiors. * Mechanized:自动化的,adj. * Personalize:使具有亲切感,v. * ...
- **severe**: 严重的,形容程度深或情况恶劣。 - **defeated**: 打败,击败,动词过去式,表示战胜对手。 2. **短语填空** - **conclusion**: 结论,此句表示警察通过仔细调查得出结论。 - **analysed**: 分析...