Server Tomcat v8.5 Server at localhost failed to start

红富
2023-12-01

在学Struts2时,遇到Tomcat报错:Server Tomcat v8.5 Server at localhost failed to start.

console台部分报错信息:

Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/struts2Helloworld2]]
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)
    ... 6 more
Caused by: java.lang.IllegalArgumentException: Filter mapping specifies an unknown filter name [struts2]

错误原因:

web.xml中<filter>和<filter-mapping>中的filter-name不一致。

解决方法:

把<filter>和<filter-mapping>中的filter-name改为一致就好了。

 

 

 类似资料:

相关阅读

相关文章

相关问答