FAIL - Application at context path /Appcould not be started by Tomcat Manager 6

5.8k views Asked by At

I was trying to deploy a war file via tomcat manager 6. Once deployed get always the same error : FAIL - Application at context path /App could not be started

The war file is under apache-tomcat-6.0.0/webapps folder.

I was googling and tried different options like :

removing apache-tomcat-6.0.0/work/Catalina/localhost folder and also apache-tomcat-6.0.0/webapps/App restarting the server and redeploying again.

As I could see in the catalinalog file :

INFO: Deploying web application archive App.war
 3:32:47 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
 2012 3:32:47 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [/App] startup failed due to previous errors
 2012 3:32:50 PM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
 2012 3:32:50 PM org.apache.catalina.core.StandardContext start
SEVERE: Context [/App] startup failed due to previous errors

Any ideas ?

1

There are 1 answers

2
Sai Hegde On

Add a “log4j.properties” file under ‘/WEB-INF/classes’ directory inside your WAR to help debug which one of the listeners is throwing this error.

This holds true for Tomcat versions < 6.0

In Tomcat 6 or above, the default logger is the”java.util.logging” logger and not Log4J. So if you are trying to add a “log4j.properties” file – this will NOT work. The Java utils logger looks for a file called “logging.properties” as stated here: http://tomcat.apache.org/tomcat-6.0-doc/logging.html

So to get to the debugging details create a “logging.properties” file under your”/WEB-INF/classes” folder of your WAR and you’re all set.

And now when you restart your Tomcat, you will see all of your debugging in it’s full glory!!!

Sample logging.properties file:

org.apache.catalina.core.ContainerBase.[Catalina].level = INFO
org.apache.catalina.core.ContainerBase.[Catalina].handlers = java.util.logging.ConsoleHandler

and you will most likely see a “ClassNotFound” exception.