当前位置: 移动技术网 > IT编程>开发语言>Java > 启动Tomcat报错 java.util.zip.ZipException: invalid LOC header (bad signature)

启动Tomcat报错 java.util.zip.ZipException: invalid LOC header (bad signature)

2019年01月04日  | 移动技术网IT编程  | 我要评论

具体错误信息如下:

信息: starting servlet engine: apache tomcat/7.0.65
2018-1-23 14:31:28 org.apache.catalina.startup.contextconfig processannotationsjar
严重: unable to process jar entry [org/apache/tools/ant/antclassloader$resourceenumeration.class] from jar [jar:file:/c:/program%20files/apache%20software%20foundation/tomcat%207.0/wtpwebapps/ordercenter-web-admin/web-inf/lib/ant-1.9.6.jar!/] for annotations
java.util.zip.zipexception: invalid loc header (bad signature)
    at java.util.zip.zipfile.read(native method)
    at java.util.zip.zipfile.access$1200(unknown source)
    at java.util.zip.zipfile$zipfileinputstream.read(unknown source)

分析一下错误:

通过上面的错误信息可以发现:是在加载 web-inf/lib/ 下的 ant-1.9.6.jar 包时发生的错误:invalid loc header (bad signature)。

解决方法:

1、在maven仓库中删除 ant 文件夹,让 maven 重新下载。

2、重新打开eclipse。

如对本文有疑问, 点击进行留言回复!!

相关文章:

验证码:
移动技术网