Exception:Failed to start component [StandardEngine[Catalina... NoClassDefFoundError:org/apache/log4
来源:互联网 发布:php 面向对象 太烂 编辑:程序博客网 时间:2024/06/11 03:29
启动Tomcat组件失败
描述:org.apache.catalina.LifecycleException:Failed to start component[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/ztsanma]]
….
Caused by:java.lang.NoClassDefFoundError:org/apache/log4j/Priority
org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/ztsanma]]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:652)at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1263)at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1975)at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)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:744)Caused by: java.lang.NoClassDefFoundError: org/apache/log4j/Priorityat java.lang.Class.getDeclaredFields0(Native Method)at java.lang.Class.privateGetDeclaredFields(Class.java:2397)at java.lang.Class.getDeclaredFields(Class.java:1806)
问题解析:
Maven项目中所有依赖(jdk/jar/classes)关系都被其管理。所以如果确定项目中确实存在该包或文件(org/apache/log4j/Priority),那必定是项目没有添加maven依赖所致。
解决方案:
右键报错项目-->属性 -->Deployment Assembly -->Add -->Java buid path entries -->Next -->MavenDependencies
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Get it!!!!!
0 0
- Exception:Failed to start component [StandardEngine[Catalina... NoClassDefFoundError:org/apache/log4
- org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].Standard
- Struts2: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina]
- org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].Standard
- org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].Standar
- org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].Standard
- org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].Standard
- org.apache.catalina.LifecycleException: Failed to start component [StandardEngine [Catalina].Standa
- org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].Standard
- Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalin
- 启动spring出错 org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catal
- tomcat 启动报错org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalin
- 每日一得--web项目报org.apache.catalina.LifecycleException: Failed to start component [StandardEngine...
- Failed to start component [StandardEngine[Catalina].StandardHost[localhost]. at org.apache.catali
- Tomcat启动报错:org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalin
- Failed to start component [StandardEngine[Catalina].
- 解决: Failed to start component [StandardEngine[Catalina]
- org.apache.catalina.LifecycleException: Failed to start component [StandardService[Catalina]]
- python——函数
- Give the common ancestor of all the deepest nodes of a tree
- 最近公共祖先
- android开发 使用RecycleView加载数据
- 使用vlc实现视频TS流的推送
- Exception:Failed to start component [StandardEngine[Catalina... NoClassDefFoundError:org/apache/log4
- java 通过URL请求获取结果(http协议)
- useful url
- php浮点数的精度问题深究
- Redis 介绍
- 数学概念
- log4j根据不同模块配置
- JMeter学习(四)参数化
- 构图之法(二)