Tag Archives: Failed to start component

[Sp;ved] Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/ssm]

tomcat startup error:

Error Messages:
Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/ssm]]
Servlet mapping specifies an unknown servlet name [springDispatcherServlet]
error messages:

Severe: Subcontainer start failure
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/ssm]]
	at java.util.concurrent.FutureTask.report(FutureTask.java:122)
	at java.util.concurrent.FutureTask.get(FutureTask.java:192)
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:916)
	at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:841)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1384)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1374)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
	at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134)
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:909)
	at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	at org.apache.catalina.core.StandardService.startInternal(StandardService.java:421)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:930)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	at org.apache.catalina.startup.Catalina.start(Catalina.java:633)
	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:343)
	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:474)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/ssm]]
	at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:440)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:198)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1384)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1374)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at org.apache.tomcat.util.threads.InlineExecutorService.execute(InlineExecutorService.java:75)
	at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:134)
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:909)
	... 21 more
Caused by: java.lang.IllegalArgumentException: Servlet mapping specifies an unknown servlet name [springDispatcherServlet]
	at org.apache.catalina.core.StandardContext.addServletMappingDecoded(StandardContext.java:3179)
	at org.apache.catalina.Context.addServletMappingDecoded(Context.java:881)
	at org.apache.catalina.startup.ContextConfig.configureContext(ContextConfig.java:1391)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1168)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:774)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:301)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5056)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	... 27 more
	十月 21, 2021 1:52:20 δΈ‹εˆ org.apache.catalina.startup.Catalina start
Severe: The required service component failed to start, so Tomcat could not be started
LifecycleException: child container failed to start
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:928)
	at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	at org.apache.catalina.core.StandardService.startInternal(StandardService.java:421)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:930)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	at org.apache.catalina.startup.Catalina.start(Catalina.java:633)
	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:343)
	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:474)
Caused by: java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: child container failed to start
	at java.util.concurrent.FutureTask.report(FutureTask.java:122)
	at java.util.concurrent.FutureTask.get(FutureTask.java:192)
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:916)
	... 13 more
	Caused by: java.lang.IllegalArgumentException: Servlet mapping specifies an unknown servlet name [springDispatcherServlet]
	at org.apache.catalina.core.StandardContext.addServletMappingDecoded(StandardContext.java:3179)
	at org.apache.catalina.Context.addServletMappingDecoded(Context.java:881)
	at org.apache.catalina.startup.ContextConfig.configureContext(ContextConfig.java:1391)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1168)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:774)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:301)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5056)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183)
	... 27 more

Solution:

In the web.xml configuration, the names of servlet name and servlet mapping are inconsistent, resulting in changing the name in servlet mapping to dispatcher servlet
note:

note: because I have a dispatcher servlet-servlet.xml file, the name should correspond!

tomcat Issues org.apache.catalina.LifecycleException: Failed to start component

1. Problem description

Sep 09, 2019 11:38:05 AM org.apache.catalina.core.ContainerBase startInternal
Warning: A child container failed during start
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/third]]
	at java.util.concurrent.FutureTask.report(FutureTask.java:122)
	at java.util.concurrent.FutureTask.get(FutureTask.java:188)
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1120)
	at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:819)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1572)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1562)
	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/third]]
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:153)
	... 6 more
Caused by: java.lang.IllegalStateException: Unable to complete the scan for annotations for web application [/third] 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:2178)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2124)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1985)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1946)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1931)
	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:5472)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	... 6 more

Sep 09, 2019 11:38:05 AM org.apache.catalina.core.ContainerBase startInternal
Warning: A child container failed during start
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]]
	at java.util.concurrent.FutureTask.report(FutureTask.java:122)
	at java.util.concurrent.FutureTask.get(FutureTask.java:188)
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1120)
	at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:300)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	at org.apache.catalina.core.StandardService.startInternal(StandardService.java:444)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:738)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	at org.apache.catalina.startup.Catalina.start(Catalina.java:693)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:606)
	at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:428)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]]
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:153)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1572)
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1562)
	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.catalina.LifecycleException: A child container failed during start
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1128)
	at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:819)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	... 6 more

Sep 09, 2019 11:38:05 AM org.apache.catalina.startup.Catalina start
Warning: The required Server component failed to start so Tomcat is unable to start.
org.apache.catalina.LifecycleException: Failed to start component [StandardServer[8005]]
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:153)
	at org.apache.catalina.startup.Catalina.start(Catalina.java:693)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:606)
	at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:428)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Catalina]]
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:153)
	at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:738)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	... 7 more
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina]]
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:153)
	at org.apache.catalina.core.StandardService.startInternal(StandardService.java:444)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	... 9 more
Caused by: org.apache.catalina.LifecycleException: A child container failed during start
	at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1128)
	at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:300)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
	... 11 more

Sep 09, 2019 11:38:05 AM org.apache.coyote.AbstractProtocol pause
Message: Pausing ProtocolHandler ["http-bio-8080"]
Sep 09, 2019 11:38:05 AM org.apache.coyote.AbstractProtocol pause
Message: Pausing ProtocolHandler ["ajp-bio-8009"]
Sep 09, 2019 11:38:05 AM org.apache.catalina.core.StandardService stopInternal
Message: Stopping service Catalina
Sep 09, 2019 11:38:05 AM org.apache.coyote.AbstractProtocol destroy
Message: Destroying ProtocolHandler ["http-bio-8080"]
Sep 09, 2019 11:38:05 AM org.apache.coyote.AbstractProtocol destroy
Message: Destroying ProtocolHandler ["ajp-bio-8009"]

2. Solutions
Just adjust your Tomcat memory parameters

-Xms256m -Xmx512m -XX:PermSize=256M -XX:MaxPermSize=512m