Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problem starting tomcat on linux

 
Chris-Huisman
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I had tomcat up and running on redhat 8.0, now it will not start for some reason. here is the error i get when trying to start it:
log4j:WARN No appenders could be found for logger
(org.apache.commons.digester.Digester).
log4j:WARN Please initialize the log4j system properly.
Catalina.start: java.lang.ClassNotFoundException:
org.apache.catalina.core.StandardServer
java.lang.ClassNotFoundException: org.apache.catalina.core.StandardServer
at org.apache.commons.digester.Digester.createSAXException(Digester.java:2540)
at org.apache.commons.digester.Digester.createSAXException(Digester.java:2566)
at org.apache.commons.digester.Digester.startElement(Digester.java:1276)at
org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(Unknown Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown
Source)
at
org.apache.xerces.impl.XMLDocumentScannerImpl$ContentDispatcher.scanRootElementHook(Unknown
Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown
Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
Source)
at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.commons.digester.Digester.parse(Digester.java:1548)
at org.apache.catalina.startup.Catalina.start(Catalina.java:449)
at org.apache.catalina.startup.Catalina.execute(Catalina.java:400)
at org.apache.catalina.startup.Catalina.process(Catalina.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203)

what is catalina.core.StandardServer? I have servlet.jar in TOMCAT_HOME/common/lib. And it was working previously. The only changes I've made are to the servlet.xml file, and that was just to add a new context.
thanks,
c.
 
Chris-Huisman
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Okay, I did a little more digging, and figured out that catalina.jar is in TOMCAT_HOME/server/lib.
I don't think I should have to (because I've never had to before) put this on my classpath. Tomcat should find it, should it not?
c.
 
heath carlough
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am a new but since nobody answered, I'll gonna take a shot and maybe it might provide some clues.
First of all what log file is this output from? Its possible that tomcat started but your context (or one of them) cannot find a jar that is needed. Did you try the default context (root or examples??). Remember to put any jars (That you need to compile or run the application in the WEB-INF/lib directory of that context), $TOMCAT_HOME/common/lib sometimes doesn't work.
But 1. check your context entry and see if the xml is well formatted (though the error doesn't seem to suggest that)
2. See if a log file is being created for the context/application itself? (if you switched loggin in the <context> declaration) that particular log file may provides some more clues.
3. Put jars needed in the WEB-INF/lib directory of the context.
hope this helps
 
Chris-Huisman
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the comment, but I reinstalled tomcat and everything is running properly now. Although the error still bothers me. If anyone knows why it occurs, I'm still interested in knowing.
c.
 
Frank Prumbaum
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Could it be you had log4j-1.2.9.jar in /common/lib?
It was the reason I got the same error.

Greetings
Frank
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic