RE: Problem with mod_jk Connector
Hi Martin, Below is my entire workers.properties file: workers.tomcat_home=/usr/local/jakarta/jakarta-tomcat workers.java_home=/usr/local/j2sdk ps=/ worker.list=ajp13 worker.ajp13.type=ajp13 worker.ajp13.host=localhost worker.ajp13.port=8009 worker.ajp13.lbfactor=50 worker.ajp13.cachesize=10 worker.ajp13.cache_timeout=600 worker.ajp13.socket_keepalive=1 worker.ajp13.socket_timeout=300 I have set JKLogLevel to info but although the problem occurs nothing goes there. In fact even for requests forwarded from Apache to Tomcat there are no entries in mod_jk.log. Regarding forwardAll I am not aware of this option, where does it go? Please note that eventually I need to have the JKUnmount in my httpd.conf. Thanks, Michael -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: 10 December 2005 23:02 To: [EMAIL PROTECTED] Cc: 'Tomcat Users List' Subject: Re: Problem with mod_jk Connector what this says is that all requests goto ajp13 worker I will need to see worker.properties file and the value of forwardAll set JkLogLevel info Martin- - Original Message - From: Michael Andreas Omerou [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org; 'Martin Gainty' [EMAIL PROTECTED] Sent: Saturday, December 10, 2005 2:33 PM Subject: RE: Problem with mod_jk Connector Hi Martin, Below is the extract from my httpd.conf: LoadModule jk_module modules/mod_jk-1.2.15-solaris8-sparc-apache-1.3.33.so JkWorkersFile /usr/local/etc/httpd/conf/workers.properties JkLogFile /usr/local/etc/httpd/logs/mod_jk.log JkLogLevel error JkMount /* ajp13 The idea is that all requests (jsp, servlets, images, etc.) are forwarded from Apache to Tomcat and this works fine with mod_jk version 1.2.5. When I upgraded to 1.2.15 though the forwards still work but only if there are no URL parameters. This is what I cannot understand: if there are URL parameters then it looks as if Apache tried to serve the request instead of forwarding to Tomcat. Any help will be much appreciated. Thanks in advance, Michael -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: 10 December 2005 17:50 To: [EMAIL PROTECTED] Cc: users@tomcat.apache.org Subject: Re: Problem with mod_jk Connector Michael- in your httpd.conf we need to see JKMount statement for handling *.jsp pages see http://tomcat.apache.org/tomcat-4.1-doc/config/jk.html e.g. For example the following directives will send all requests ending in .jsp or with /servlet as the second path componenet to the ajp13 worker, but jsp requests to files located in /otherworker will go to remoteworker. JkMount /*.jsp ajp13 JkMount /*/servlet/ ajp13 JkMount /otherworker/*.jsp remoteworker Martin-- Original Message - From: Michael Andreas Omerou [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Saturday, December 10, 2005 10:25 AM Subject: Problem with mod_jk Connector Hello, I have a Solaris server where I use Apache and Tomcat and I connect them using mod_jk. So far I was using mod_jk 1.2.5 and all requests to Apache were forwarded to Tomcat. Then, I needed to host some things under Apache (basically web statistics software, webmail, etc.). So I thought of using JkUnmount to do this. JkUnmoun is not supported from mod_jk 1.2.5 so I installed the latest version 1.2.15. Now JkUnmount works but I have another problem. If a url which is meant to be sent to Tomcat contains URL parameters, e.g. something like ./hotelDetails.jsp?hotelCode=AMY, then the request is not forwarded from Apache/Mod_jk. I checked everywhere for solutions to this but could not find any. Your help willl be much appreciated. Rgds, Michael - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with mod_jk Connector
Straight from the doc available at http://tomcat.apache.org/connectors-doc/config/apache.html forwardAll=true in your httpd.conf forwards ALL requests to tomcat JkUnMount takes precedence over JkMount directives, meaning that the JK will first look for unmount and then for mount directives. The following example will block all .gif files. # do not send requests ending with .gif to worker1 JkUnMount /*.gif worker1 # The .gif files will not be mounted cause JkUnMount takes # precedence over JkMount directive JkMount /servlet/*.gif worker1so in effect your JkUnmount statement is blocking access to the parameter following JkUnmount commandMartin- - Original Message - From: Michael Andreas Omerou [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org; 'Martin Gainty' [EMAIL PROTECTED] Sent: Sunday, December 11, 2005 3:57 AM Subject: RE: Problem with mod_jk Connector Hi Martin, Below is my entire workers.properties file: workers.tomcat_home=/usr/local/jakarta/jakarta-tomcat workers.java_home=/usr/local/j2sdk ps=/ worker.list=ajp13 worker.ajp13.type=ajp13 worker.ajp13.host=localhost worker.ajp13.port=8009 worker.ajp13.lbfactor=50 worker.ajp13.cachesize=10 worker.ajp13.cache_timeout=600 worker.ajp13.socket_keepalive=1 worker.ajp13.socket_timeout=300 I have set JKLogLevel to info but although the problem occurs nothing goes there. In fact even for requests forwarded from Apache to Tomcat there are no entries in mod_jk.log. Regarding forwardAll I am not aware of this option, where does it go? Please note that eventually I need to have the JKUnmount in my httpd.conf. Thanks, Michael -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: 10 December 2005 23:02 To: [EMAIL PROTECTED] Cc: 'Tomcat Users List' Subject: Re: Problem with mod_jk Connector what this says is that all requests goto ajp13 worker I will need to see worker.properties file and the value of forwardAll set JkLogLevel info Martin- - Original Message - From: Michael Andreas Omerou [EMAIL PROTECTED] To: 'Tomcat Users List' users@tomcat.apache.org; 'Martin Gainty' [EMAIL PROTECTED] Sent: Saturday, December 10, 2005 2:33 PM Subject: RE: Problem with mod_jk Connector Hi Martin, Below is the extract from my httpd.conf: LoadModule jk_module modules/mod_jk-1.2.15-solaris8-sparc-apache-1.3.33.so JkWorkersFile /usr/local/etc/httpd/conf/workers.properties JkLogFile /usr/local/etc/httpd/logs/mod_jk.log JkLogLevel error JkMount /* ajp13 The idea is that all requests (jsp, servlets, images, etc.) are forwarded from Apache to Tomcat and this works fine with mod_jk version 1.2.5. When I upgraded to 1.2.15 though the forwards still work but only if there are no URL parameters. This is what I cannot understand: if there are URL parameters then it looks as if Apache tried to serve the request instead of forwarding to Tomcat. Any help will be much appreciated. Thanks in advance, Michael -Original Message- From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: 10 December 2005 17:50 To: [EMAIL PROTECTED] Cc: users@tomcat.apache.org Subject: Re: Problem with mod_jk Connector Michael- in your httpd.conf we need to see JKMount statement for handling *.jsp pages see http://tomcat.apache.org/tomcat-4.1-doc/config/jk.html e.g. For example the following directives will send all requests ending in .jsp or with /servlet as the second path componenet to the ajp13 worker, but jsp requests to files located in /otherworker will go to remoteworker. JkMount /*.jsp ajp13 JkMount /*/servlet/ ajp13 JkMount /otherworker/*.jsp remoteworker Martin-- Original Message - From: Michael Andreas Omerou [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Saturday, December 10, 2005 10:25 AM Subject: Problem with mod_jk Connector Hello, I have a Solaris server where I use Apache and Tomcat and I connect them using mod_jk. So far I was using mod_jk 1.2.5 and all requests to Apache were forwarded to Tomcat. Then, I needed to host some things under Apache (basically web statistics software, webmail, etc.). So I thought of using JkUnmount to do this. JkUnmoun is not supported from mod_jk 1.2.5 so I installed the latest version 1.2.15. Now JkUnmount works but I have another problem. If a url which is meant to be sent to Tomcat contains URL parameters, e.g. something like ./hotelDetails.jsp?hotelCode=AMY, then the request is not forwarded from Apache/Mod_jk. I checked everywhere for solutions to this but could not find any. Your help willl be much appreciated. Rgds, Michael - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JSP/Servlet runs even when webapp undeployed
From: Darren Holloway [mailto:[EMAIL PROTECTED] Subject: JSP/Servlet runs even when webapp undeployed However, if I undeploy the web-app, it continues to run. If I deploy another version of the web-app, it still uses the original one. A few things to try: 1) Take httpd out of the picture, just to make things simpler. Test using Tomcat's http port (usually 8080). Once you find and fix the problem, verify that operation through Apache is also corrected. 2) Look around for a Context tag for your webapp that has a docBase attribute pointing to somewhere other than Tomcat's webapps directory. This can be in META-INF/context.xml in the app's .war file or directory, in conf/Catalina/host_name/app_name.xml, or in conf/server.xml (which shouldn't be used these days). Your app may be getting deployed multiple times under different names if there's more than one Context tag for it. 3) Look around for the compiled JSP class, and get rid of it if found. Your undeploy mechanism should have done this for you. (What are you using to undeploy?) - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How to start web service application before the web client applic ation
I have both web service and web client application deployed to local host. How can I make tomcat load web service application before web client application? Thanks in advance.
I got other problem
I make the jsp file work but this time i have other exception I hope you can help me Communication link failure: java.io.IOException, underlying cause: Unexpected end of input stream ** BEGIN NESTED EXCEPTION ** java.io IOException MESSAGE: Unexpected end of input stream STACKTRACE: java.io IOException: Unexpected end of input stream at com.mysql.jdbc.MysqlIO readPacket(MysqlIO.java:1096) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO java:626) at com.mysql.jdbc.Connection.createNewIO(Connection.java:1562) at com.mysql.jdbc.Connection.(Connection.java:491) at com.mysql.jdbc NonRegisteringDriver.connect(NonRegisteringDriver.java:346) at java.sql DriverManager.getConnection(Unknown Source) at java.sql.DriverManager getConnection(Unknown Source) at org.apache.jsp.colors.prueba_jsp _jspService(org.apache.jsp.colors.prueba_jsp:55) at org.apache.jasper runtime.HttpJspBase.service(HttpJspBase.java:97) at javax.servlet.http HttpServlet.service(HttpServlet.java:802) at org.apache.jasper.servlet JspServletWrapper.service(JspServletWrapper.java:322) at org.apache.jasper servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper servlet.JspServlet.service(JspServlet.java:264) at javax.servlet.http HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase java:432) at org.apache.catalina.core.StandardHostValve invoke(StandardHostValve.java:126) at org.apache.catalina.valves ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:831) at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler process(Http11AprProtocol.java:652) at org.apache.tomcat.util.net AprEndpoint$Worker.run(AprEndpoint.java:1203) at java.lang.Thread run(Unknown Source) ** END NESTED EXCEPTION ** Thanks on advance Claudio Veas
Re: I got other problem
Claudio- what happens when you start MySQL as a service? Saludos Cordiales de EEUU Martin- - Original Message - From: Claudio Veas [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Sunday, December 11, 2005 8:56 PM Subject: I got other problem I make the jsp file work but this time i have other exception I hope you can help me Communication link failure: java.io.IOException, underlying cause: Unexpected end of input stream ** BEGIN NESTED EXCEPTION ** java.io IOException MESSAGE: Unexpected end of input stream STACKTRACE: java.io IOException: Unexpected end of input stream at com.mysql.jdbc.MysqlIO readPacket(MysqlIO.java:1096) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO java:626) at com.mysql.jdbc.Connection.createNewIO(Connection.java:1562) at com.mysql.jdbc.Connection.(Connection.java:491) at com.mysql.jdbc NonRegisteringDriver.connect(NonRegisteringDriver.java:346) at java.sql DriverManager.getConnection(Unknown Source) at java.sql.DriverManager getConnection(Unknown Source) at org.apache.jsp.colors.prueba_jsp _jspService(org.apache.jsp.colors.prueba_jsp:55) at org.apache.jasper runtime.HttpJspBase.service(HttpJspBase.java:97) at javax.servlet.http HttpServlet.service(HttpServlet.java:802) at org.apache.jasper.servlet JspServletWrapper.service(JspServletWrapper.java:322) at org.apache.jasper servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper servlet.JspServlet.service(JspServlet.java:264) at javax.servlet.http HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase java:432) at org.apache.catalina.core.StandardHostValve invoke(StandardHostValve.java:126) at org.apache.catalina.valves ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:831) at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler process(Http11AprProtocol.java:652) at org.apache.tomcat.util.net AprEndpoint$Worker.run(AprEndpoint.java:1203) at java.lang.Thread run(Unknown Source) ** END NESTED EXCEPTION ** Thanks on advance Claudio Veas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
I made it
Sorry to bother with my problem, but i could figure it out by self, thanks for your question Martin I apreciate it your concern, oh and the problem was that I had an old java-connector so I downloadaded the last and the aplication worked so Im really happy. By the way why does the mailing list administrator tells me that my mails are spam thats nota a tomcat question but its about the mailing list. Thanks to all who read my mail. Claudio Veas ---Original Message--- From: Martin Gainty Date: 12/11/05 23:36:59 To: [EMAIL PROTECTED] Cc: Tomcat Users List Subject: Re: I got other problem Claudio- what happens when you start MySQL as a service? Saludos Cordiales de EEUU Martin- - Original Message - From: Claudio Veas [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Sunday, December 11, 2005 8:56 PM Subject: I got other problem I make the jsp file work but this time i have other exception I hope you can help me Communication link failure: java.io.IOException, underlying cause: Unexpected end of input stream ** BEGIN NESTED EXCEPTION ** java.io IOException MESSAGE: Unexpected end of input stream STACKTRACE: java.io IOException: Unexpected end of input stream at com.mysql.jdbc.MysqlIO readPacket(MysqlIO.java:1096) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO java:626) at com.mysql.jdbc.Connection.createNewIO(Connection.java:1562) at com.mysql.jdbc.Connection.(Connection.java:491) at com.mysql.jdbc NonRegisteringDriver.connect(NonRegisteringDriver.java:346) at java.sql DriverManager.getConnection(Unknown Source) at java.sql.DriverManager getConnection(Unknown Source) at org.apache.jsp.colors.prueba_jsp _jspService(org.apache.jsp.colors.prueba_jsp:55) at org.apache.jasper runtime.HttpJspBase.service(HttpJspBase.java:97) at javax.servlet.http HttpServlet.service(HttpServlet.java:802) at org.apache.jasper.servlet JspServletWrapper.service(JspServletWrapper.java:322) at org.apache.jasper servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper servlet.JspServlet.service(JspServlet.java:264) at javax.servlet.http HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase java:432) at org.apache.catalina.core.StandardHostValve invoke(StandardHostValve.java:126) at org.apache.catalina.valves ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:831) at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler process(Http11AprProtocol.java:652) at org.apache.tomcat.util.net AprEndpoint$Worker.run(AprEndpoint.java:1203) at java.lang.Thread run(Unknown Source) ** END NESTED EXCEPTION ** Thanks on advance Claudio Veas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to load a class when tomcat starts
Hi Vineesh, Thats simple. Just check the link below for information on ServletContextListener. This is just according to the Servlet spec with tomcat its just as easy: http://java.sun.com/products/servlet/2.3/javadoc/javax/servlet/ServletContextListener.html Sample code: ApplicationListener.java package xxx; import javax.servlet.ServletContextListener; import javax.servlet.ServletContextEvent; public class ApplicationListener implements ServletContextListener { public void contextInitialized(ServletContextEvent cse) { System.out.println(Application initialized); //call any other class here } public void contextDestroyed(ServletContextEvent cse) { System.out.println(Application shut down); //do any clean up here } } Add this class to web.xml: ?xml version=1.0 encoding=ISO-8859-1? !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN http://java.sun.com/dtd/web-app_2_3.dtd; web-app listener listener-classxxx.ApplicationListener/listener-class /listener /web-app Add the relevant classes to web-inf/classes, start your app and its all done. Thanks, Prabhu S -Original Message- From: vineesh kumar [mailto:[EMAIL PROTECTED] Sent: Friday, December 09, 2005 11:07 AM To: Tomcat Users List; [EMAIL PROTECTED] Subject: How to load a class when tomcat starts Hi all, I need to load a java class when tomcat starts, which will initializes some configuration files and so i can use the fields in the class throught the environment.How can i do this.? Actually I am working on a distributed application, so the configuration files may change frequently but once the system is initialized it will not change until shut down. regards vineesh This e-mail and any files transmitted with it are for the sole use of the intended recipient(s) and may contain confidential and privileged information. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message. Any unauthorized review, use, disclosure, dissemination, forwarding, printing or copying of this email or any action taken in reliance on this e-mail is strictly prohibited and may be unlawful. Visit us at http://www.cognizant.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to start web service application before the web client applic ation
On Sun, Dec 11, 2005 at 07:00:25PM -0500, Vasudha Kini wrote: : I have both web service and web client application deployed to local host. : : How can I make tomcat load web service application before web client : application? 1/ run apps in separate Tomcat containers -- start the service app container before the client app container 2/ hack the Tomcat source code to force a load order Technically, there's no reliable way to do this if you insist on running both apps in the same container. Java web apps are supposed to be fairly self-contained and otherwise independent of one another; as such, a design that relies on app start order is in need of review. -QM -- software -- http://www.brandxdev.net/ tech news -- http://www.RoarNetworX.com/ code scan -- http://www.JxRef.org/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Exception in thread main java.lang.NoClassDefFoundError: org/apache/catalina/startup/Bootstrap - tomcat + Linux
From: rafiti [mailto:[EMAIL PROTECTED] Subject: Exception in thread main java.lang.NoClassDefFoundError: org/apache/catalina/startup/Bootstrap - tomcat + Linux Using CATALINA_BASE: /home2/rafi/jakarta-tomcat-4.1.31-src/ Using CATALINA_HOME: /home2/rafi/jakarta-tomcat-4.1.31-src/catalina/src Using CATALINA_TMPDIR: /home2/rafi/jakarta-tomcat-4.1.31-src//temp Judging from the directory names, it appears that you have downloaded, installed, and are now trying to run the source for Tomcat, not the binary distribution. By the way, if you're just starting, why not use the current version of Tomcat? - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problems with my first JSP file
When starting a new thread (ie sending a message to the list about a new topic) please do not reply to an existing message and change the subject line. To many of the list archiving services and mail clients used by list subscribers this makes your new message appear as part of the old thread. This makes it harder for other users to find relevant information when searching the lists. This is known as thread hijacking and is behaviour that is frowned upon on this list. Frequent offenders will be removed from the list. It should also be noted that many list subscribers automatically ignore any messages that hijack another thread. The correct procedure is to create a new message with a new subject. This will start a new thread. Mark tomcat-user-owner Claudio Veas wrote: Im already on my learning path but I have a problem on my first example and I dont know exactly what it is. This is the JSP File HTML HEADTITLEEmployee List/TITLE/HEAD BODY %@ page import=java.sql.* % TABLE BORDER=1 width=75% TRTHLast Name/THTHFirst Name/TH/TR % Connection conn = null; Statement st = null; ResultSet rs = null; try { Class.forName(com.mysql.jdbc.Driver).newInstance(); conn = DriverManager.getConnection(jdbc:mysql://localhost:3306/test,jonas,jonas); st = conn.createStatement(); rs = st.executeQuery(select * from employees); while(rs.next()) { % TRTD%= rs.getString(lname_txt) %/TD TD%= rs.getString(fname_txt) %/TD/TR % } % /TABLE % } catch (Exception ex) { ex.printStackTrace(); % %= ex.getMessage() % /TABLE Ooops, something bad happened: % } finally { if (rs != null) rs.close(); if (st != null) st.close(); if (conn != null) conn.close(); } % /BODY /HTML and this is the output I get When I try to see it I have some experience using the JDBC with mysql and i tried to use the ex.getSQLState() function but I got an error. I really hope you can help me Thanks on advance. Claudio Veas Add FUN to your email - CLICK HERE! http://www.incredimail.com/index.asp?id=96769 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Session cookies on Linux
Hi list, I have a problem with session cookies on a Linux server. Both Tomcat instances running on the machine don't seem to be able to store session data in cookies. They otherwise work just fine, just no cookies. I have obviously checked all browser settings as well as made sure that all webapps in question have the cookie flag turned on. However, Tomcat is still not setting any cookies... My set-up: - Suse Linux server (kernel 2.6.8-24.18-smp) - Multiprocessor machine with 4 GB memory - Sun VM 1.4.2_08-b03 - 2 Tomcat 5.0.28 instances Maybe this is a problem with fileset permission's? Tomcat runs as user tomcat and I think I checked each dir Tomcat needs to write into but I am not sure where cookies are normally stored in. Is this the temp dir or somewhere else? I would be very grateful for any help or suggestions as to what to do to get this fixed. TIA, Jan Jan Behrens OFFIS FuE-Bereich Betriebliches Informationsmanagement Escherweg 2 - 26121 Oldenburg - Germany Fon: +49 4 41 97 22 - 187 - Fax: +49 4 41 97 22-102 E-mail: [EMAIL PROTECTED] - URL: http://www.offis.de - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]