Sermilion
Sermilion

Reputation: 2049

Tomcat (7, 8) fails to start with java.lang.ClassNotFoundException: org.apache.tomcat.util.res.StringManager

I am trying to install Apache Tomcat to OS X El Capitan. I followed these instructions, that basically ask to download, unpack and run start script. However, when I enter localhost or localhost:8080, home page does not open. I checked and Tomcat is configured to port 8080. I checked if the port is busy wit command sudo lsof -i :8080 which shows that is not being used. Further, I checked catalina.outand found this log message:

java.lang.NoClassDefFoundError: org/apache/tomcat/util/res/StringManager
    at org.apache.catalina.startup.Catalina.<clinit>(Catalina.java:74)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
    at java.lang.Class.newInstance(Class.java:442)
    at org.apache.catalina.startup.Bootstrap.init(Bootstrap.java:268)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:455)
Caused by: java.lang.ClassNotFoundException: org.apache.tomcat.util.res.StringManager
    at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    ... 8 more

I tried to search for the Exception online, but could not find anything.

I also tried to download fresh copy of Tomcat (7 and 8) but still same Exception is thrown.

Hope someone can help me to find solution for this. Thank you.

Upvotes: 3

Views: 8593

Answers (1)

Medu
Medu

Reputation: 133

Do you have the tomcat-util.jar in your {CATALINA_HOME}/lib folder? If that is present then there must be an issue with your tomcat classpath.

Upvotes: 2

Related Questions