Where to begin? Tomcat is not unstable. If you have been editing setclaspath.sh then you should probably start with a fresh tomcat install. You don't have to edit that file and who knows what else has been changed. Go download tomcat (don't use the Ubuntu version). Untar it. Don't copy your app into it yet. cd into bin and do 'catalina.sh run' and see if tomcat starts up. ctr-c to shut it down.
Where are you putting your DB2 driver? Post your web.xml Are you using a war file? Why are you running tomcat as root? ________________________________________ From: Ariela Carrera [EMAIL PROTECTED] Sent: Sunday, November 23, 2008 9:42 PM To: Tomcat Users Subject: Tomcat 6 unstable Hi dear users of Tomcat. I am writing to you because my webapp is not working fine. I am developing a web application with Java, a Servlet and JSP some in Tomcat 6.0.14, using Ubuntu Gutsy. I have developed a class that connects to DB2, which I tested plenty of times, with a kind of test, for console. The kind of connection is working properly. THE PROBLEM: Although it always starts well, charging that brings all the examples of jsp and servlet correctly, TOMCAT feature when you want, 1) Loading or not my servlet, 2) Losing or no connections to DB2, and 3) Making nulls or not, values in the http-Sesions. Without having made any changes in the source code, Tomcat sometimes do works and sometimes do not. SOLUTIONS I TRIED: - I tried to start adding the-Xmx but I do not see differences. Tomcat also remains unstable. - I tried to create the folder CATALINAHOME/common/lib (version 6 brings no folder) and there copying the jar needed. I continue as before. - I tried editing the setclaspath.sh, since in the first few lines, what it does is literally erasing the entire class that has ... Well, there was a CLASSPATH = "" and it changed by a CLASSPATH = $ CLASSPATH, this way it is not deleting the old value of the variable. - I tried booting java as a server with the-server. What else can I try? I accept any suggestion DETAILS What am I using? JAVA VERSION: $ java-version Java (TM) SE Runtime Environment (build 1.6.0_02-B05) Java HotSpot (TM) Client VM (build 1.6.0_02-B05, mixed mode) Javac VERSION: $ javac-version javac 1.6.0_02 By starting TOMCAT: $ sudo /opt/apache-tomcat-6.0.14/bin/./startup.sh Using CATALINA_BASE: /opt/apache-tomcat-6.0.14 Using CATALINA_HOME: /opt/apache-tomcat-6.0.14 Using CATALINA_TMPDIR: /opt/apache-tomcat-6.0.14/temp Using JRE_HOME: /opt/java/jdk/jre OUTPUT FOR PROBLEM 1) java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet java.lang.ClassLoader.defineClass1(Native Method) java.lang.ClassLoader.defineClass(ClassLoader.java:620) java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) java.net.URLClassLoader.defineClass(URLClassLoader.java:260) java.net.URLClassLoader.access$000(URLClassLoader.java:56) java.net.URLClassLoader$1.run(URLClassLoader.java:195) java.security.AccessController.doPrivileged(Native Method) java.net.URLClassLoader.findClass(URLClassLoader.java:188) java.lang.ClassLoader.loadClass(ClassLoader.java:306) sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276) java.lang.ClassLoader.loadClass(ClassLoader.java:251) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1273) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1204) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:263) org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:584) org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) java.lang.Thread.run(Thread.java:619) OUTPUT FOR PROBLEMS 2) and 3) org.apache.jasper.JasperException: java.lang.NullPointerException org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:541) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:435) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) javax.servlet.http.HttpServlet.service(HttpServlet.java:803) causa raíz java.lang.NullPointerException org.apache.jsp.query_002dadd_002d2_jsp._jspService(query_002dadd_002d2_jsp.java:107) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) javax.servlet.http.HttpServlet.service(HttpServlet.java:803) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) javax.servlet.http.HttpServlet.service(HttpServlet.java:803) If you had any idea why Tomcat is so unstable, please answer me. I really need to make this work. Best regards, *~ Ariela ~* ¡Todo sobre Amor y Sexo! La guía completa para tu vida en Mujer de Hoy. http://mx.mujer.yahoo.com/ --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]