Tomcat啟動報錯:嚴重: Unable to process Jar entry [module-info.class]
1、Spring boot 版本:2.1.4.RELEASE
2、Tomcat版本:apache-tomcat-8.0.30
3、原因:Tomcat版本底,Spring boot 2.1.4對應的Tomcat版本應該是:tomcat 8.5.16以上
4、報錯代碼:
嚴重: Unable to process Jar entry [module-info.class] from Jar [jar:file:/D:/STS/Workspaces/Cloudview/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/task-starter/WEB-INF/lib/jaxb-api-2.3.1.jar!/] for annotationsorg.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19 at org.apache.tomcat.util.bcel.classfile.Constant.readConstant(Constant.java:97) at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:55) at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:176) at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:85) at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2011) at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1961) at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1936) at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1897) at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1149) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:771) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:305) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:95) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) 五月 10, 2019 9:25:46 上午 org.apache.catalina.startup.ContextConfig processAnnotationsJar嚴重: Unable to process Jar entry [META-INF/versions/9/module-info.class] from Jar [jar:file:/D:/STS/Workspaces/Cloudview/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/task-starter/WEB-INF/lib/byte-buddy-1.9.12.jar!/] for annotationsorg.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19 at org.apache.tomcat.util.bcel.classfile.Constant.readConstant(Constant.java:97) at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:55) at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:176) at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:85) at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2011) at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1961) at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1936) at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1897) at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1149) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:771) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:305) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:95) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
5、解決方法:
打開tomcat\conf\catalina.properties文件
tomcat.util.scan.StandardJarScanFilter.jarsToSkip節點增加 byte-buddy-1.9.12.jar,jaxb-api-2.3.1.jar
注意:Eclipse中的Tomcat刪除后重新創建后才生效。
其中增加的節點是你報錯的jar包
到此這篇關于Tomcat啟動報錯:嚴重: Unable to process Jar entry [module-info.class]的文章就介紹到這了,更多相關Tomcat啟動報錯內容請搜索好吧啦網以前的文章或繼續瀏覽下面的相關文章希望大家以后多多支持好吧啦網!
相關文章:
1. Tomcat啟動核心流程示例詳解2. 關于Tomcat啟動失敗報循環依賴的問題解決(AncestorAxisIterator)3. 傳統tomcat啟動服務與springboot啟動內置tomcat服務的區別(推薦)4. 解讀Tomcat啟動、重啟、暫停操作(window)5. 解決Tomcat啟動失敗:嚴重 [main] org.apache.catalina.util.LifecycleBase.handleSubClassException 初始化組件失敗6. 為什么我的tomcat啟動不起來7. 解決tomcat啟動 ssm項目出現亂碼的問題8. Tomcat啟動成功但無法訪問http://localhost:8080/的解決方法9. tomcat啟動異常:子容器啟動失敗(a child container failed during start)