"Offending Class:javax/servlet/servlet.class" error in Tomcat: Duplicate servlet package __offending

Source: Internet
Author: User
Tags apache tomcat

After you start Tomcat, the console finds "offending Class:javax/servlet/servlet.class" information:

Using catalina_home: "D:\apache-tomcat-7.0.52" Using Catalina_tmpdir: "D:\apache-tomcat-7.0.52\temp"
Using jre_home: "D:\jdk1.7.0_51"
Using CLASSPATH: "D:\apache-tomcat-7.0.52\bin\bootstrap.jar;d:\apache-tomcat-7.0.52\bin\tomcat-juli.jar"
February 28, 2014 10:30:50 pm org.apache.coyote.AbstractProtocol Init
Info: Initializing Protocolhandler ["http-bio-8080"]
February 28, 2014 10:30:50 pm org.apache.coyote.AbstractProtocol Init
Info: Initializing Protocolhandler ["ajp-bio-8009"]
February 28, 2014 10:30:50 pm Org.apache.catalina.startup.Catalina Load
Info: Initialization processed in 931 ms
February 28, 2014 10:30:50 pm Org.apache.catalina.core.StandardService startinternal
Info: Starting service Catalina
February 28, 2014 10:30:50 pm Org.apache.catalina.core.StandardEngine startinternal
Info: Starting Servlet engine:apache tomcat/7.0.52
February 28, 2014 10:30:50 pm org.apache.catalina.startup.HostConfig deploydescriptor
Info: Deploying configuration Descriptor C:\Documents and settings\xxx\. Intellijidea11\system\tomcat\unnamed_myapp\conf\catalina\localhost\root.xml
February 28, 2014 10:30:50 pm Org.apache.catalina.loader.WebappClassLoader validatejarfile
Info: Validatejarfile (E:\code\MyApp\target\MyApp\WEB-INF\lib\servlet-api-3.0-alpha-1.jar)-jar not loaded. For a Servlet Spec 3.0, section 10.7.2. Offending Class:javax/servlet/servlet.class

Log4j:warn No Appenders could is found for logger (org.springframework.web.context.ContextLoader).

According to the tip, the servlet Spec 3.0,10.7.2 chapter was searched online:

Furthermore, the ClassLoader instance must be a separate instance for each deployed Web application.


The reason for this problem is that there is a duplicate servlet package under Web-info/lib in WebApp. After you remove the servlet package from the WebApp deployment file. Restart, and the error message disappears.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.