RE: JSP compilation
Try putting your class file in WEB-INF/lib/classes Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 -Original Message- From: Milan Tomic [mailto:[EMAIL PROTECTED] Sent: Monday, November 21, 2005 11:42 AM To: 'Tomcat Users List' Subject: RE: JSP compilation Thank you. With your help, I found it. :) I still have a problem that I can't use my custom classes in JSPs. I am beginner with Tomcat and JSPs. I have created one simple class: public class TestClass { public TestClass () {} } and compiled it. Then I copied it (TestClass.class file) into apache-tomcat-5.5.12\webapps\jsp-examples\WEB-INF\lib. This is my test JSP page: <%@ page import="TestClass" %> <% TestCLass tc = new TestClass(); %> The problem is that I got this exception: org.apache.jasper.JasperException: Unable to compile class for JSP Generated servlet error: The import TestClass cannot be resolved An error occurred at line: 2 in the jsp file: /demo/TestMe.jsp Generated servlet error: TestCLass cannot be resolved to a type Can you help me? :( Milan -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: Monday, November 21, 2005 6:12 PM To: Tomcat Users List Subject: Re: JSP compilation TestMe.class is not the file created. Look in $TOMCAT_INSTALLATION/work/. It'll probably be called TestMe_jsp.class -Tim Milan Tomic wrote: > > > I have created simple TestMe.jsp page and when I open it in Tomcat, I can > see it OK. The problem is that I can't find, using WinXP WE search engine, > TestMe.class file. Where is it? Are JSP files compiled? > > - 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: JSPs on Tomcat
And make sure that the imported classes are part of some package Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 -Original Message- From: Mark Thomas [mailto:[EMAIL PROTECTED] Sent: Monday, November 21, 2005 12:55 PM To: Tomcat Users List Subject: Re: JSPs on Tomcat Milan Tomic wrote: > > > I have problems running JSPs on Tomcat. I'm using latest release. I got > compiler error that some imported classes could not be found. Where should I > copy those classes? In the lib folder? Do I need to edit some configuration > (xml) files also? Place the jars in the lib folder. No config required. Mark - 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: Java databases as alternative to MySQL on OS X Server? (OT)
Cloudscape, now owned by IBM is a good choice. It can be run as a Standalone server or as an imbedded db running within the JVM with your code. I haven't used it lately, but developed some stuff a few years ago when Sun use to ship it with the J2EE package. Richard Schilling wrote: You might try a Java Data Objects implementation: www.objectdb.com java.sun.com/products/jdo/index.jsp These are pure object databases, and are reasonably fast. The Sun's reference implementation of JDO is not intended for production use but it's great as a development toolkit. Richard Schilling Mieke Banderas wrote: Given the sad, sad performance findings at: "No More Apple Mysteries, Part Two" Date: September 1st, 2005 <http://www.anandtech.com/mac/showdoc.aspx?i=2520> are there any javabased DB alternatives, that may perform better than MySQL (or PostgreSQL for that matter)? I prefer free, open sourced DBs or otherwise with a license that could fit a small business/non profit organisation. I don't enough of JVMs to know if Javabased DBs are usually better performancewise than MySQL/PostgreSQL, but my thought was that if everything is kept within the JVM, the weak performance spots in OS X would be minimized as threads would be handled within JVM rather than within OS X. Threads being being the prime suspect in the weak MySQL performance in OS X according Anandtech. Do you have any thought and/or suggestions on this issue? Experiences you could share? My server runs Mac OS X Server 10.2.6 with Java 1.4.1/1.3.1. I can't use Java 1.5 just yet. - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 5.0 HTTP 404 with hello.class
Try changing you mapping slightly ... this is how I do it and it works Hello /hello/* Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 -Original Message- From: White-Home.com [mailto:[EMAIL PROTECTED] Sent: Monday, January 02, 2006 8:57 PM To: users@tomcat.apache.org Subject: Tomcat 5.0 HTTP 404 with hello.class As I understand it I can save Hello.class as /usr/share/tomcat5/webapps/hello/WEB-INF/classes/com/hello/Hello.class and address is as http://localhost:8080/hello/Hello This results in a HTTP 404 error message. Background I am running Linux FC4 and Tomcat 5.0.30 I have a hello.jsp in the /usr/share/tomcat5/webapps/hello directory that works with http://localhost:8080/hello/hello.jsp. I have a hello.xml in the /usr/share/tomcat5/conf/Catalina/localhost directory pointing to the hello directory. I restart tomcat with each update. I have a web.xml file in the /usr/share/tomcat5/webapps/hello/WEB-INF directory with the following: http://java.sun.com/xml/ns/j2ee"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"; version="2.4"> Hello com.hello.Hello Hello /hello I have not been able to detect an error, this test is really simple. I build the class without errors and copy it into the directory. The group is set to tomcat. Any help would be appreciated. Mike [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Please help, i have to be missing something very simple
Do you have a package statement in your servlet? You should Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 -Original Message- From: Randy Paries [mailto:[EMAIL PROTECTED] Sent: Friday, January 06, 2006 3:24 PM To: users@tomcat.apache.org Subject: Please help, i have to be missing something very simple Hello, I am moving an App from a devel server to a production server When i run the app everything works fine except the new stuff (of course) in my servlet i am calling Color bgcolor = new Color( Integer.parseInt(album.getBGcolor().substring(1), 16) ) ; and as soon as i do i get Class not found FYI i am using tomcat-5.0.24 ./catalina.sh run Using CATALINA_BASE: /usr/java/jakarta-tomcat Using CATALINA_HOME: /usr/java/jakarta-tomcat Using CATALINA_TMPDIR: /usr/java/jakarta-tomcat/temp Using JAVA_HOME: /usr/java/j2sdk1.4.2_04 classpath=/usr/java/j2sdk1.4.2_04/lib/tools.jar:/usr/java/jakarta-tomcat /bin/bootstrap.jar:/usr/java/j2sdk1.4.2_04:/usr/java/j2sdk1.4.2_04/lib path=/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin :/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/java/j2sdk1.4.2_04/bi n:/root/bin java_home=/usr/java/j2sdk1.4.2_04 Any ideas what i am overlooking. It has to be simple == StandardWrapperValve[galleryPubServlet]: Servlet.service() for servlet galleryPubServlet threw exception java.lang.NoClassDefFoundError at galleryPubServlet.startUpload(galleryPubServlet.java:245) at galleryPubServlet.MYdoGet(galleryPubServlet.java:156) at galleryPubServlet.doGet(galleryPubServlet.java:101) at galleryPubServlet.doPost(galleryPubServlet.java:66) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at javax.servlet.http.HttpServlet.service(HttpServlet.java:810) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica tionFilterChain.java:237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt erChain.java:157) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv e.java:214) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo ntext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5 20) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardCon textValve.java:198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv e.java:152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo ntext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5 20) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java :137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo ntext.java:104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java :117) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo ntext.java:102) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:535 ) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo ntext.java:102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5 20) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve. java:109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo ntext.java:104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5 20) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:296) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:372) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:694) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java: 626) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:807) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool .java:644) at java.lang.Thread.run(Thread.java:534) - 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: Please help, i have to be missing something very simple
Looks more like libawt.so has an unsatisfied link to libXp.so.6 this is a security exeption first so maybe libXp.so.6 is in a protected area somehow...either through java's sandbox or some stupid windows permissions thing Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 -Original Message- From: Randy Paries [mailto:[EMAIL PROTECTED] Sent: Friday, January 06, 2006 3:36 PM To: Tomcat Users List Subject: Re: Please help, i have to be missing something very simple I created a little test program(see below), and i get the following error java com.unitnet.utils.testcolor Just Before Exception in thread "main" java.lang.UnsatisfiedLinkError: /usr/java/j2sdk1.4.2_04/jre/lib/i386/libawt.so: libXp.so.6: cannot open shared object file: No such file or directory at java.lang.ClassLoader$NativeLibrary.load(Native Method) at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1560) at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1477) at java.lang.Runtime.loadLibrary0(Runtime.java:788) at java.lang.System.loadLibrary(System.java:834) at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:50) at java.security.AccessController.doPrivileged(Native Method) at java.awt.Toolkit.loadLibraries(Toolkit.java:1437) at java.awt.Toolkit.(Toolkit.java:1458) at java.awt.Color.(Color.java:250) at com.unitnet.utils.testcolor.main(testcolor.java:13) yet ls -ls /usr/java/j2sdk1.4.2_04/jre/lib/i386/libawt.so 2972 -rwxr-xr-x 1 root bin 3034008 Feb 24 2004 /usr/java/j2sdk1.4.2_04/jre/lib/i386/libawt.so package com.unitnet.utils; import java.awt.*; public class testcolor { public static void main (String[] args){ try{ System.out.println( "Just Before" ); Color bgcolor = new Color( 1 , false ) ; System.out.println( "Just After" ); }catch (Exception ex){ ex.printStackTrace(); } } } ======= On 1/6/06, Mike Sabroff <[EMAIL PROTECTED]> wrote: > Do you have a package statement in your servlet? > > You should > > > Mike Sabroff > Web Services Developer > [EMAIL PROTECTED] > 920-568-8379 > > -Original Message- > From: Randy Paries [mailto:[EMAIL PROTECTED] > Sent: Friday, January 06, 2006 3:24 PM > To: users@tomcat.apache.org > Subject: Please help, i have to be missing something very simple > > Hello, > I am moving an App from a devel server to a production server > > When i run the app everything works fine except the new stuff (of > course) > > in my servlet i am calling > Color bgcolor = new Color( > Integer.parseInt(album.getBGcolor().substring(1), 16) ) ; > > and as soon as i do i get Class not found > > FYI > i am using tomcat-5.0.24 > > ./catalina.sh run > Using CATALINA_BASE: /usr/java/jakarta-tomcat > Using CATALINA_HOME: /usr/java/jakarta-tomcat > Using CATALINA_TMPDIR: /usr/java/jakarta-tomcat/temp > Using JAVA_HOME: /usr/java/j2sdk1.4.2_04 > classpath=/usr/java/j2sdk1.4.2_04/lib/tools.jar:/usr/java/jakarta-tomcat > /bin/bootstrap.jar:/usr/java/j2sdk1.4.2_04:/usr/java/j2sdk1.4.2_04/lib > > path=/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin > :/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/java/j2sdk1.4.2_04/bi > n:/root/bin > > java_home=/usr/java/j2sdk1.4.2_04 > > > Any ideas what i am overlooking. It has to be simple > == > > > StandardWrapperValve[galleryPubServlet]: Servlet.service() for servlet > galleryPubServlet threw exception > java.lang.NoClassDefFoundError >at galleryPubServlet.startUpload(galleryPubServlet.java:245) >at galleryPubServlet.MYdoGet(galleryPubServlet.java:156) >at galleryPubServlet.doGet(galleryPubServlet.java:101) >at galleryPubServlet.doPost(galleryPubServlet.java:66) >at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) >at javax.servlet.http.HttpServlet.service(HttpServlet.java:810) >at > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica > tionFilterChain.java:237) >at > org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt > erChain.java:157) >at > org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv > e.java:214) >at > org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo > ntext.java:104) >at > org.apache.catalina.core.StandardPipelin
Re: tomcat 5 and cgi execution
The executable is the executable file name...perl is the name of the perl executable Mark Thomas wrote: Linda Solomon wrote: I followed the instructions for configuring tomcat 5 for cgi. However, tomcat 5 contains a new xml variable: executable - The of the executable to be used to run the script. Default is perl. Using the default allows the perl cgis to work fine, but the c++ cgi's do not work. This is unlikely to be a factor. Before it was configurable it was hard-coded to perl so if you leave it as the default there should be no functional change. There are, however, a whole stack of other changes that may be a factor. The following (rather long) URL should show you the changes. http://svn.apache.org/viewcvs.cgi/tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/servlets/CGIServlet.java?p1=tomcat%2Fcontainer%2Fcatalina%2Ftrunk%2Fcatalina%2Fsrc%2Fshare%2Forg%2Fapache%2Fcatalina%2Fservlets%2FCGIServlet.java&rev=366305&r1=302487&r2=366305&diff_format=h Mark - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk with httpd & tomcat
I had the same problem a while back. I had to do some googling and find the mod_jk source. Trying to compile it was problematic and I also got the unresolved errors I had to rebuild apache with jk as part of the build in order to get it to work. I wish I could remember where I got the source and the instructions, but I am old and forget easily (actually age has nothing to do with italways been like that) I appologize, especially since I spent many hours trying this and that and I know what you are going through I do remember, that the proceedure was different with apache 2.x than it was with 1.3x that I have installed. Greg Bobak wrote: I am using Tomcat 5.0.28 BTW. G. Greg Bobak <[EMAIL PROTECTED]> wrote: I am trying to get mod_jk to work with apache 2.0.55 and get this error on the load module: Syntax error on line 276 of /usr/local/apache2/conf/httpd.conf: Cannot load /usr/local/apache2/modules/mod_jk.so into server: ld.so.1: /usr/local/apache2/bin/httpd: fatal: relocation error: file /usr/local/apache2/modules/mod_jk.so: symbol ap_null_cleanup: referenced symbol not found I have looked everywhere, and have been advised to recompile apache, which I have done successfully a few times. This is how I have recompiled: ./configure --prefix=/usr/local/apache2 --enable-mods-shared=all --enable-ssl=shared --enable-ssl --with-ssl=/usr/local/ssl --enable-proxy --enable-proxy-connect --enable-proxy-ftp --enable-proxy-http --enable-so --enable-rule="SHARED_CORE" make make install I use "make clean" between attempts..Ihave tried withou the "SHARED_CORE" and without the --enable-so because --enable-mods-shared=all should cover that. Still no luck. I am using Solaris 9. Here is some diag info: [EMAIL PROTECTED]:/usr/local/apache2/bin # ldd -d /usr/local/apache2/modules/mod_jk.so libc.so.1 => /usr/lib/libc.so.1 libdl.so.1 =>/usr/lib/libdl.so.1 symbol not found: ap_server_root (/usr/local/apache2/modules/mod_jk.so) symbol not found: ap_null_cleanup (/usr/local/apache2/modules/mod_jk.so) symbol not found: dir_module (/usr/local/apache2/modules/mod_jk.so) /usr/platform/SUNW,Serverblade1/lib/libc_psr.so.1 [EMAIL PROTECTED]:/usr/local/apache2/bin # httpd -V Server version: Apache/2.0.55 Server built: Jan 23 2006 13:17:34 Server's Module Magic Number: 20020903:11 Architecture: 32-bit Server compiled with -D APACHE_MPM_DIR="server/mpm/prefork" -D APR_HAS_SENDFILE -D APR_HAS_MMAP -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled) -D APR_USE_FCNTL_SERIALIZE -D APR_USE_PTHREAD_SERIALIZE -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT -D APR_HAS_OTHER_CHILD -D AP_HAVE_RELIABLE_PIPED_LOGS -D HTTPD_ROOT="/usr/local/apache2" -D SUEXEC_BIN="/usr/local/apache2/bin/suexec" -D DEFAULT_PIDLOG="logs/httpd.pid" -D DEFAULT_SCOREBOARD="logs/apache_runtime_status" -D DEFAULT_LOCKFILE="logs/accept.lock" -D DEFAULT_ERRORLOG="logs/error_log" -D AP_TYPES_CONFIG_FILE="conf/mime.types" -D SERVER_CONFIG_FILE="conf/httpd.conf" [EMAIL PROTECTED]:/usr/local/apache2/bin # httpd -v Server version: Apache/2.0.55 Server built: Jan 23 2006 13:17:34 Please advise as to what info would be helpful in determining the root cause. Thanks for your help, Greg - What are the most popular cars? Find out at Yahoo! Autos - What are the most popular cars? Find out at Yahoo! Autos -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: (newb) Tomcat servlet mapping problem
/simple-servlet should be /simple-servlet/* Georg Sauer-Limbach wrote: Darren, if I look at your original configuration SimpleServlet /simple-servlet ---snip--- reloadable="true" debug="99"> then, if I am not overlooking something, the correct URL to invoke the servlet is http://localhost/simple-servlet/simple-servlet because the first "simple-servlet" is the Context path where the webapp resides, and the second "simple-servlet" is the URL for the servlet inside the webapp, like correctly configured in the webapp descriptor. Georg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk with httpd & tomcat
Yeh, I remember getting that too and I too had the right path, but just could not get it to work. Must be some environment variable like LD_LIBRARY_PATH on sun boxes or some unresolved piece of extraneous information. When you compile it into apache, that problem does not exist as it becomes part of the apache build. I do remember I had to run a configure script to make it all work...Getting old is not fun Greg Bobak wrote: Hi, Thansk for the reply. I think I had found some documentation about rebuild Apache with mod_jk bound. I'll have to look again. I've been trying to rebuild mod_jk (to no avail) in hopes that would work, but keep getting this error: could not find /usr/local/apache2/bin/apxs configure: error: You must specify a valid --with-apxs path Of course it is the right path. G. Mike Sabroff <[EMAIL PROTECTED]> wrote: I had the same problem a while back. I had to do some googling and find the mod_jk source. Trying to compile it was problematic and I also got the unresolved errors I had to rebuild apache with jk as part of the build in order to get it to work. I wish I could remember where I got the source and the instructions, but I am old and forget easily (actually age has nothing to do with italways been like that) I appologize, especially since I spent many hours trying this and that and I know what you are going through I do remember, that the proceedure was different with apache 2.x than it was with 1.3x that I have installed. Greg Bobak wrote: > > I am using Tomcat 5.0.28 BTW. > > G. > > Greg Bobak wrote: I am trying to get mod_jk to > work with apache 2.0.55 and get this error on the load module: > > Syntax error on line 276 of /usr/local/apache2/conf/httpd.conf: > Cannot load /usr/local/apache2/modules/mod_jk.so into server: ld.so.1: > /usr/local/apache2/bin/httpd: fatal: relocation error: file > /usr/local/apache2/modules/mod_jk.so: symbol ap_null_cleanup: > referenced symbol not found > > > I have looked everywhere, and have been advised to recompile apache, > which I have done successfully a few times. This is how I have > recompiled: > > ./configure --prefix=/usr/local/apache2 --enable-mods-shared=all > --enable-ssl=shared --enable-ssl --with-ssl=/usr/local/ssl > --enable-proxy --enable-proxy-connect --enable-proxy-ftp > --enable-proxy-http --enable-so --enable-rule="SHARED_CORE" > > make > > make install > > I use "make clean" between attempts..Ihave tried withou the > "SHARED_CORE" and without the --enable-so because > --enable-mods-shared=all should cover that. Still no luck. > > I am using Solaris 9. Here is some diag info: > > [EMAIL PROTECTED]:/usr/local/apache2/bin # ldd -d > /usr/local/apache2/modules/mod_jk.so > libc.so.1 => /usr/lib/libc.so.1 > libdl.so.1 =>/usr/lib/libdl.so.1 > symbol not found: ap_server_root > (/usr/local/apache2/modules/mod_jk.so) > symbol not found: ap_null_cleanup > (/usr/local/apache2/modules/mod_jk.so) > symbol not found: dir_module > (/usr/local/apache2/modules/mod_jk.so) > /usr/platform/SUNW,Serverblade1/lib/libc_psr.so.1 > > [EMAIL PROTECTED]:/usr/local/apache2/bin # httpd -V > Server version: Apache/2.0.55 > Server built: Jan 23 2006 13:17:34 > Server's Module Magic Number: 20020903:11 > Architecture: 32-bit > Server compiled with > -D APACHE_MPM_DIR="server/mpm/prefork" > -D APR_HAS_SENDFILE > -D APR_HAS_MMAP > -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled) > -D APR_USE_FCNTL_SERIALIZE > -D APR_USE_PTHREAD_SERIALIZE > -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT > -D APR_HAS_OTHER_CHILD > -D AP_HAVE_RELIABLE_PIPED_LOGS > -D HTTPD_ROOT="/usr/local/apache2" > -D SUEXEC_BIN="/usr/local/apache2/bin/suexec" > -D DEFAULT_PIDLOG="logs/httpd.pid" > -D DEFAULT_SCOREBOARD="logs/apache_runtime_status" > -D DEFAULT_LOCKFILE="logs/accept.lock" > -D DEFAULT_ERRORLOG="logs/error_log" > -D AP_TYPES_CONFIG_FILE="conf/mime.types" > -D SERVER_CONFIG_FILE="conf/httpd.conf" > > [EMAIL PROTECTED]:/usr/local/apache2/bin # httpd -v > Server version: Apache/2.0.55 > Server built: Jan 23 2006 13:17:34 > > > Please advise as to what info would be helpful in determining the root > cause. > > Thanks for your help, > Greg > > > > > > > - > > What are the most popular cars? Find out at Yahoo! Autos > > > > - > > What are the most popular cars? Find out at Yahoo! Autos > -- Mike Sabroff Web Services De
Re: https difficulties w/ Tomcat5
it works fine for me in 5.5.12 I haven't tried 5.5.15isn't that still in beta status?? [EMAIL PROTECTED] wrote: I had the same problem with Tomcat 5.5.12. Finally someone told me to check the Tomcat 5.5\bin directory for a file called tcnative-1.dll (or something like that, I don't remember exactly). After I deleted that file, my SSL connections worked fine. -- Original message -- From: "Stevie G. Messervey" <[EMAIL PROTECTED]> Hello, Please let me preface that I have actually tried to run down various threads,tutorials,FAQS, and the Tomcat docs (both shipped & online). dist: Crux Evolution 2.0.x kernel: 2.6.8.1 gcc:3.3.4 java:jdk1.5.0_06 kde:3.3(incl/konqueror) firefox:1.5 Tomcat:5.5.15 (binary tar.gz) APR:1.2.2 Basically, I cannot get the SSL connector to work. I uncomment the appropriate entry in server.xml, and when I try to access https://localhost:8443,the session times out. Oddly (to me), accessing via http://localhost:8080 works. I do have the keystore properly configured, as I recently installed 4.1.31 to test it. Tomcat4.1.31 w/ https works flawlessly. I chased this thing round and round- I downloaded firefox, thinking maybe it was a browser issue, as I built KDE myself(i.e. it's not the bundle from the distro). Same issue. I don't really suspect gcc or associated problems,as jsvc and libtcnative both compiled (and installed, for libtcnative) w/o complaint. I have even tried copying a modified from 4.1.31, which (unmodified) works under 4.1.31 . I have tried explicitly setting the address, i.e. address="127.0.0.1"; no luck. I created some scripts to monitor the tomcat sessions, the most useful fragment being 'neststat -p | grep localhost:', which, during my tests, shows tomcat talking to itself, from which I can conclude that the sessions are being started. The only thing I haven't tried is building from source. In short, has anyone else been able to: * get https working, 'out of the box', from the 5.5.15 binary .tar.gz? * ditto above, with Crux? Crux-Evolution? Thank you for your time and interest, Tarkin __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: mod_jk / 503 Error
className="org.apache.ajp.tomcat4.config.ApacheConfig" append="true" forwardAll="false" jkWorker="ajp13" workersConfig="/home/usr/tomcat/conf/workers.properties" modJk="/dh/apache/template/libexec/mod_jk.so" /> - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem in tomcat configuration...
"module not included in the server configuration"this is the key mod_jk is a third party module and is not in the apache distribution. It must be downloaded and compiled. Best way is to compile it into the apache executable. You will have to go to the tomcat docs and maybe google to find info on how to do this..plan on spending some time. Bharat Soni wrote: Hi, I have RH9, apache 2.0.40,tomcat 4.3.11 jdk 1.3.1_11. with mysql 3.23.54. I am installing a server with apache+mod jk + tomcat + mysql. The problem is that after writing Include /usr/local/tomcat/conf/auto/mod_jk.so in my httpd.conf file and trying to start the httpd server i got error as Syntax error on line 28 of /usr/local/tomcat/conf/auto/mod_jk.conf: Invalid command 'JkMount', perhaps mis-spelled or defined by a module not included in the server configuration . I have build my apache as ./configure --prefix=/usr/local/apache --enable-openssl --enable-so on net I found this below command. ./configure --prefix=/usr/local/apache --enable-ssl --enable-so But for my setup this command was not working and gives some ssl error . I query for the RPM and find openssl on my system. so i used the command with openssl included. is this correct ot this is the cause for the problem. By the way Tomcat is working fine individually . but due to the error apache is not starting. if i comment the line apache also works fine . Thanks in anticipation Bharat Soni +91-9826098373 -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How do I stop tomcat when the port is in use
kill -9 (unix) task manager (windows) Shankar Unni wrote: Koneru, Narendra wrote: When the port that I specify to start tomcat is in use, then I want tomcat to go down after printing a message. What I observed is that tomcat prints the message on the screen that there is a bind exception but tomcat server does not go down. Do you have some servlet marked for whose init() starts threads, or anything like that? And the thread is not created as a "daemon" thread (setDaemon(true))? That can cause this behavior. Or, if any of your servlets throws an exception, that sometimes screws up the shutdown.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: APR Connector Shutdown Problem
Try switching to a ajp1.3 connector - "cyote" if you can...AJP are fairly new and problematic from what I have seen and heard Fenlason, Josh wrote: I'm running into a problem with the APR connector not shutting down properly. Tomcat runs fine and there are no errors on shutdown, but if I shut Tomcat down and start it up again I get a socket bind failed error in the catalina log (attached). I have to wait for several minutes between shutdown and startup for Tomcat to be able to startup correctly. If I run Tomcat without the APR connector, I don't have this issue. This does not occur on Windows, but does on Solaris and AIX. Has anyone else seen this? One thing I noticed is that the first thing logged on shutdown is an "AjpAprProtocol pause" entry, but there is no shutdown, stop or destroy. Is there any chance the APR connector is just getting paused and nothing is actually stopping it? Any help would be greatly appreciated. Thanks in advance. , Josh. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5.9 + JDK 1.4.2 + Freebsd 5.3
use startup.sh Vinu Varghese wrote: Hi, I am running Tomcat 5.5.9 with JDK 1.4.2 on freebsd 5.3. I use the 'catalina.sh start' to start tomcat. Now it creates a bunch of java processes - which can be seen using ps command. Now the problem is when I shutdown tomcat with command 'catalina.sh stop' , still there exists some java processes that doesn't get killed. Why is this so ? - Regards Vinu -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5.9 + JDK 1.4.2 + Freebsd 5.3
and shutdown.sh Vinu Varghese wrote: Hi, I am running Tomcat 5.5.9 with JDK 1.4.2 on freebsd 5.3. I use the 'catalina.sh start' to start tomcat. Now it creates a bunch of java processes - which can be seen using ps command. Now the problem is when I shutdown tomcat with command 'catalina.sh stop' , still there exists some java processes that doesn't get killed. Why is this so ? - Regards Vinu -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5.9 + JDK 1.4.2 + Freebsd 5.3
I can't answer that, but it seems to make a difference. It also helps to have a "setenv.sh" which contains all of the environment variables i.e CATALINA_HOME JAVA_HOME, etc. catalina.sh looks for this. Actually, I never tried to go straight to the catalina.sh Vinu Varghese wrote: Hi Mike Thank you. But what is difference in using startup.sh and catalina.sh start. The startup.sh simply calls catalina.sh with start . - Regards Vinu Mike Sabroff wrote: and shutdown.sh Vinu Varghese wrote: Hi, I am running Tomcat 5.5.9 with JDK 1.4.2 on freebsd 5.3. I use the 'catalina.sh start' to start tomcat. Now it creates a bunch of java processes - which can be seen using ps command. Now the problem is when I shutdown tomcat with command 'catalina.sh stop' , still there exists some java processes that doesn't get killed. Why is this so ? - Regards Vinu -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: can't send email from tomcat using javamail api
it is the smtp server that is rejecting the connection.do you need to authenticate to your smtp server? Matthew Evans wrote: I don't think so. The webapp is currently able to make SOAP calls to another server on the network. And connect to a SQL Server database. Where would you suggest I check to be sure? Cheers Matt -Original Message- From: Leon Rosenberg [mailto:[EMAIL PROTECTED] Sent: Thursday, 2 February 2006 3:01 AM To: Tomcat Users List Subject: Re: can't send email from tomcat using javamail api just shooting from the hip... do you have any java policies configured, which forbids connections to another server? Leon On 2/1/06, Matthew Evans <[EMAIL PROTECTED]> wrote: No, it's running on a different server. -Original Message- From: Steve Ochani [mailto:[EMAIL PROTECTED] Sent: Thursday, 2 February 2006 1:59 AM To: Tomcat Users List; Matthew Evans Subject: Re: can't send email from tomcat using javamail api On 2 Feb 2006 at 0:12, Matthew Evans wrote: Hi Guys I'm running a web application on Tomcat 5.5.12, and I cannot connect to my SMTP server using javamail from it for some reason. The error I am getting is the following:- javax.mail.MessagingException: Could not connect to SMTP host: smtpServer, port: 25; nested exception is: java.net.ConnectException: Connection refused: connect What has me totally confused though is that I can telnet to the SMTP server on port 25. I also made a little test java application to run outside of tomcat and it succesfully sent an email to the same server! Does anyone know what might be causing this. Why would it be failing only from the web application? I have tried just about everything i can think of. Is the webapp running on the same server as the SMTP server? If so then you have to run telnet on that server itselft and connect to localhost on port 25 to do a true test. The reason why I'm suggesting this is that the smtp server may not be configured to accept localhost connections. -Steve O. $BS!kTS!!)S!kTS!!)S!kTS!!)S!kTS!!)S!kTS!!)S!kTS!!)S!kTS!(J There's no obfuscated Perl contest because it's pointless. - Jeff Polk Steve O. http://www.steveo.us New pics: B17G and B24 http://www.steveo.us/B17-B24 B17G WWII Bomber "Yankee Lady" Flight http://www.steveo.us/b17ride SUNY NCC MATH/COMPUTER Dept. http://www.matcmp.ncc.edu - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: can't send email from tomcat using javamail api
There are also a few other things. I had this happen one time, and it was a dns problemanother time it was another networking problem. Whatever it is, like I said beforeor should have restated as: it appears that java is attempting to make the connection, but is being refused for some reason or anotherpossibly authentication, or very possibly a network issue (this is very likely) Mike Sabroff wrote: it is the smtp server that is rejecting the connection.do you need to authenticate to your smtp server? Matthew Evans wrote: I don't think so. The webapp is currently able to make SOAP calls to another server on the network. And connect to a SQL Server database. Where would you suggest I check to be sure? Cheers Matt -Original Message- From: Leon Rosenberg [mailto:[EMAIL PROTECTED] Sent: Thursday, 2 February 2006 3:01 AM To: Tomcat Users List Subject: Re: can't send email from tomcat using javamail api just shooting from the hip... do you have any java policies configured, which forbids connections to another server? Leon On 2/1/06, Matthew Evans <[EMAIL PROTECTED]> wrote: No, it's running on a different server. -Original Message- From: Steve Ochani [mailto:[EMAIL PROTECTED] Sent: Thursday, 2 February 2006 1:59 AM To: Tomcat Users List; Matthew Evans Subject: Re: can't send email from tomcat using javamail api On 2 Feb 2006 at 0:12, Matthew Evans wrote: Hi Guys I'm running a web application on Tomcat 5.5.12, and I cannot connect to my SMTP server using javamail from it for some reason. The error I am getting is the following:- javax.mail.MessagingException: Could not connect to SMTP host: smtpServer, port: 25; nested exception is: java.net.ConnectException: Connection refused: connect What has me totally confused though is that I can telnet to the SMTP server on port 25. I also made a little test java application to run outside of tomcat and it succesfully sent an email to the same server! Does anyone know what might be causing this. Why would it be failing only from the web application? I have tried just about everything i can think of. Is the webapp running on the same server as the SMTP server? If so then you have to run telnet on that server itselft and connect to localhost on port 25 to do a true test. The reason why I'm suggesting this is that the smtp server may not be configured to accept localhost connections. -Steve O. $BS!kTS!!)S!kTS!!)S!kTS!!)S!kTS!!)S!kTS!!)S!kTS!!)S!kTS!(J There's no obfuscated Perl contest because it's pointless. - Jeff Polk Steve O. http://www.steveo.us New pics: B17G and B24 http://www.steveo.us/B17-B24 B17G WWII Bomber "Yankee Lady" Flight http://www.steveo.us/b17ride SUNY NCC MATH/COMPUTER Dept. http://www.matcmp.ncc.edu - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to identify version of a running Tomcat and similar trivia
go to tomcat/bin type "catalina.sh version" output will look like: Using CATALINA_BASE: /usr/local/tomcat Using CATALINA_HOME: /usr/local/tomcat Using CATALINA_TMPDIR: /usr/local/tomcat/temp Using JRE_HOME: /usr/local/java Server version: Apache Tomcat/5.5.12 Server built: Sep 23 2005 09:40:42 Server number: 5.5.12.0 OS Name:Linux OS Version: 2.6.11-1.1369_FC4 Architecture: i386 JVM Version:1.5.0_06-b05 JVM Vendor: Sun Microsystems Inc. Tim Funk wrote: Tomcat is like any server based java app. It will always require a convulted classpath as well as multiple classloaders to do anything interesting. The most failsafe way to get the version regarless of the packaging is to do the following: (no, i'm not kidding) 1) find catalina.jar. It *should* be in server/lib/catalina.jar of your tomcat installation 2) Open it with winzip like program 3) Look for ServerInfo.properties (in org/apache/catalina/util/) 4) In that file is ther server version The version.sh script is just a wrapper the created the appropriate classpath so that the properties file can be loaded. -Tim [EMAIL PROTECTED] wrote: Hi Tim, Only problem is, my Tomcat depot on this box (randomly picked one of our HP-UX boxes, but we also have Tomcats running on Linux, AIX, Solaris (and probably Win32) doesn't seem to have bundled such a wrapper script. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 4.1.31 & IBM JDK & JSSE crash
The error is for com.ibm.jsse.bd not com.sun.jsse or whatever. Youneed IBM's jsse it appears Philippe Couas wrote: Hi, I use an Tomcat 4.1.31 wit IBM JDK 1.4.1 and i want Implement JSSE on my Tomcat I have add Sun jsse.jar on $JAVA_HOME/jre/lib/ext but i have following error, where is my mistake ?? Regards Philippe - Root Cause - java.security.NoSuchAlgorithmException: Class com.ibm.jsse.bd configured for SSL Context not a SSLContext at com.sun.net.ssl.SunJSSE_b.a(DashoA12275) Philippe COUAS Responsable D�veloppement INFODEV S.A. -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Strange problem with tomcat Please help
no route to host is a dns or network problem. it would not be in the catalina.out do a ps on apache...you will probably find that the default fedora setup (unless you did not set up web server on installation) is to install and run apache on boot-up which would be on port 80. [EMAIL PROTECTED] wrote: Hi all I am a newbie to tomcat. I installed jarkarta tomcat 5.5.9 with fedoracore3 OS. I already have j2sdk1.5.2 installed on it. I downloaded and configured tomcat from http://www.coreservlets.com/Apache-Tomcat-Tutorial/tomcat5.5-files/jakarta-= tomcat-5.5.9-preconfigured.zip<http://www.coreservlets.com/Apache-Tomcat-Tutorial/tomcat5.5-files/jakarta-=tomcat-5.5.9-preconfigured.zip> After configuring tomcat, and i run http://localhost:8080/ from firefox in my pc, it works fine and shows me the index.html in webapps directory. Other files like index.jsp, hello.jsp are working fine too. However, when i access it from any other pc saying http://mypcname:8080/ it gives me an error saying "No route to host" . However when i type http://mypcname/ it works fine and is accessible. That is on port 80, it works fine. Even other hosts like http://someotherhost:8080/ , my pc isnt accessible. I dont understand my it is giving me the error saying "No route to host" when accessing from other pc. I am using the server.xml from coreservelets.com The following seems to be running when i saw in ps -x 9908 pts/1Sl 0:03 /usr/local/j2sdk1.4.2_10/bin /java - Djava.util.logging.manager =3Dorg.apache.juli.ClassLoaderLogManage I checked out catalina.out, but that didnt not contain any errors for "No route to host". Please help thanks -Rsh -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Port 8443 won't become active (UNCLASSIFIED)
JAVA_HOME/jre/lib/security/java.security:ssl.KeyManagerFactory.algorithm=SunX509 JAVA_HOME/jre/lib/deploy.jar - found in here JAVA_HOME/jre/lib/jsse.jar - and here This is the default for a normal sun installation. What IBM does is unknown, but if tomcat sees the IBM release and NOT the Sun/java release.I don't know, but I would thing IBM would have taken care of this Samara, Fadi N Mr ACSIM/ASPEX wrote: Classification: UNCLASSIFIED Caveats: NONE Have you generated key pairs yet ? -Original Message- From: Jeffery G. Summers [mailto:[EMAIL PROTECTED] Sent: Friday, February 03, 2006 11:24 AM To: 'Tomcat Users List' Subject: RE: Port 8443 won't become active OK, so it isn't the java version. I've ensured JAVA_HOME is correct and that the PATH is pointing to the right version. All the jars are running through 1.4.2. I'm stumped. I've gone through various docs/faqs and can't find anything that helps. I know port 8443 can be activated because I changed the http port 80 connector to port 8443. I connected to my site using :8443 in the url but, of course, it's not https. The only thing I can see that appears to be an issue is this error in the logs: Feb 3, 2006 6:57:54 AM org.apache.catalina.startup.Catalina start SEVERE: Catalina.start: LifecycleException: Protocol handler start failed: java.io.IOException: Algorithm SunX509 not available I've no idea how to resolve this issue. Any clues? I've found some obscure info on changing something called java.secure and making sure a few jar files exist, but I don't know where this java.secure file is, how it should be edited (if it really needs it) or where I should get the jar files since we don't have them (Jcert.JAR , jNET.JAR,jSSE.jar in jre/lib/ext) Thanks! Jeff -Original Message- From: Jeffery G. Summers [mailto:[EMAIL PROTECTED] Sent: Thursday, February 02, 2006 1:53 PM To: 'Tomcat Users List' Subject: RE: Port 8443 won't become active When we contracted our upgrades the consultant installed version 1.4.2 but when I just ran "java -version" the box tells me that 1.3.1 is the one running in memory! I've never stopped/started java, etc. and I plan on making the consultant finish the job on this...but, if I want to try it does anyone have a "Quickie Guide" I could use? Thanks! Jeff -Original Message- From: Peter Crowther [mailto:[EMAIL PROTECTED] Sent: Thursday, February 02, 2006 12:28 PM To: Tomcat Users List Subject: RE: Port 8443 won't become active From: Jeffery G. Summers [mailto:[EMAIL PROTECTED] Our webserver is an IBM P615C AIX 5.2 box. Whose JVM and what version? - Peter Successfully scanned by McAfee SIG 3200 Appliance. Successfully Scanned by the McAfee SIG 3200 Appliance. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Successfully scanned by McAfee SIG 3200 Appliance. Successfully Scanned by the McAfee SIG 3200 Appliance. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Classification: UNCLASSIFIED Caveats: NONE ----- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Port 8443 won't become active (UNCLASSIFIED)
I don't know if that will take care of it, but I would try changing the catalina.properties (tomcat/conf) it has some references to "sun". There may be some access problems on the IBM classes or packages that need to be set in heremaybe just adding the equivalent IBM packages may solve the problem. This is an uneducated guess, not a fact. BTW...have you checked IBM's site for info on tomcat integration? Jeffery G. Summers wrote: Mike, In our JAVA_HOME/jre/lib/security/java.security the following exists: ssl.KeyManagerFactory.algorithm=IbmX509 ssl.TrustManagerFactory.algorithm=IbmX509 We have no JAVA_HOME/jre/lib/deploy.jar or jsse.jar. Our error log says SunX509 while the above obviously has IbmX509. I'm guessing that Tomcat has a setting somewhere that specifies SunX509 - can anyone tell me where that is? I'm assuming I can change it to IbmX509??? Please advise! Thanks! jeff -----Original Message- From: Mike Sabroff [mailto:[EMAIL PROTECTED] Sent: Friday, February 03, 2006 11:43 AM To: Tomcat Users List Subject: Re: Port 8443 won't become active (UNCLASSIFIED) JAVA_HOME/jre/lib/security/java.security:ssl.KeyManagerFactory.algorithm=Sun X509 JAVA_HOME/jre/lib/deploy.jar - found in here JAVA_HOME/jre/lib/jsse.jar - and here This is the default for a normal sun installation. What IBM does is unknown, but if tomcat sees the IBM release and NOT the Sun/java release.I don't know, but I would thing IBM would have taken care of this Samara, Fadi N Mr ACSIM/ASPEX wrote: Classification: UNCLASSIFIED Caveats: NONE Have you generated key pairs yet ? -Original Message- From: Jeffery G. Summers [mailto:[EMAIL PROTECTED] Sent: Friday, February 03, 2006 11:24 AM To: 'Tomcat Users List' Subject: RE: Port 8443 won't become active OK, so it isn't the java version. I've ensured JAVA_HOME is correct and that the PATH is pointing to the right version. All the jars are running through 1.4.2. I'm stumped. I've gone through various docs/faqs and can't find anything that helps. I know port 8443 can be activated because I changed the http port 80 connector to port 8443. I connected to my site using :8443 in the url but, of course, it's not https. The only thing I can see that appears to be an issue is this error in the logs: Feb 3, 2006 6:57:54 AM org.apache.catalina.startup.Catalina start SEVERE: Catalina.start: LifecycleException: Protocol handler start failed: java.io.IOException: Algorithm SunX509 not available I've no idea how to resolve this issue. Any clues? I've found some obscure info on changing something called java.secure and making sure a few jar files exist, but I don't know where this java.secure file is, how it should be edited (if it really needs it) or where I should get the jar files since we don't have them (Jcert.JAR , jNET.JAR,jSSE.jar in jre/lib/ext) Thanks! Jeff -Original Message- From: Jeffery G. Summers [mailto:[EMAIL PROTECTED] Sent: Thursday, February 02, 2006 1:53 PM To: 'Tomcat Users List' Subject: RE: Port 8443 won't become active When we contracted our upgrades the consultant installed version 1.4.2 but when I just ran "java -version" the box tells me that 1.3.1 is the one running in memory! I've never stopped/started java, etc. and I plan on making the consultant finish the job on this...but, if I want to try it does anyone have a "Quickie Guide" I could use? Thanks! Jeff -Original Message- From: Peter Crowther [mailto:[EMAIL PROTECTED] Sent: Thursday, February 02, 2006 12:28 PM To: Tomcat Users List Subject: RE: Port 8443 won't become active From: Jeffery G. Summers [mailto:[EMAIL PROTECTED] Our webserver is an IBM P615C AIX 5.2 box. Whose JVM and what version? - Peter Successfully scanned by McAfee SIG 3200 Appliance. Successfully Scanned by the McAfee SIG 3200 Appliance. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Successfully scanned by McAfee SIG 3200 Appliance. Successfully Scanned by the McAfee SIG 3200 Appliance. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Classification: UNCLASSIFIED Caveats: NONE ----- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: tomcat/linux no xserver problem
why not just install the Xserver Abhilash Kumar wrote: You have Batik (ships with FOP distribution itself) in Tomcat's classpath ? Pls see wheter this link is helpful. http://xmlgraphics.apache.org/fop/0.20.5/graphics.html#batik thanks and regards, -- Kannan. -Original Message- From: Eickvonder Bjoern [mailto:[EMAIL PROTECTED] Sent: Monday, February 06, 2006 11:50 AM To: users@tomcat.apache.org Subject: tomcat/linux no xserver problem Hi, one of our customers is using tomcat 5.0.28 with jdk 1.4.2_05 on linux without a running xserver. In fact there is not even one installed. Now our application produces the following exceptions on generating pdfs using fop: 1.) java.lang.UnsatisfiedLinkError: /usr/java/j2sdk1.4.2_05/jre/lib/i386/libawt.so: libXp.so.6: cannot open shared object file: No such file or directory 2.) java.lang.NoClassDefFoundError at org.apache.fop.svg.SVGUserAgent.getViewportSize(SVGUserAgent.java:145) [This line of code is just: "return new Dimension(100, 100);"] The first we solved by setting the headless parameter and installing some basic x-win libraries, but the second exception is still thrown in some cases. To be more precise it seems that now all pdfs are generated except those with embedded svg (using fo:foreign-instream-object). Anyone an idea what might be still missing or misconfigured on the server? Bjoern Eickvonder Besuchen Sie uns vom 14.02. bis zum 16.02.2006 auf der Learntec in Karlsruhe auf unserem Messestand 342. Vereinbaren Sie einen Termin mit uns... Diese E-Mail enthalt vertrauliche und/oder rechtlich geschutzte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtumlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail bzw. Inhalte hieraus ist nicht gestattet. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Amritha Institute of Medical Sciences, Cochin, India Sent using "PostMaster" by QuantumLink Communications One Internet account, unlimited personal e-mail addresses Get your free copy of "PostMaster" at http://www.mailserve.net/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can we stop tomcat using System.exit(int)
when you call System.exit(), you shut down the jvm. It is no wonder that tomcat gets hung. you don't want to make your code specific to tomcat, but yet you want to shut tomcat down?? write a method that does a system call, "kill -9 pid" catalina.pid is a file containing the pid of the tomcat instance (found in CATALINA_HOME or wherever your environment is set to put in. If you switch servlet engines, this will still work with minor modifications. crude, but so is System.exit(). [EMAIL PROTECTED] wrote: Hi, My web application requires database pool connection while startup, when it fails for any reason I need to stop the tomcat server as well. I have used System.exit(int); int here I tried with Zero and non-zero value. The result is tomcat gets hung. I understand it has to do with Java rather than Tomcat, however I'm looking for a suggestion to stop tomcat in a way similar to the above. I have learnt to stop tomcat a) programmatically using Bootstrap classes, (stops successfully only if you start programmatically) b) by invoking shutdown.sh c) by connecting to the server at port 8005, and send the shutdown string. All the above methods have yielded the same result, moreover it would make my application coded specific to tomcat or Linux; I have also googled with the phrase "~tomcat crash", "stop ~tomcat", "system.exit ~tomcat", ""system.exit ~jvm""; to at least find out that the task cannot be done, however it helped me a little. Here are the versions of server, os and java I'm using. Tomcat: 5.x OS : Red Hat Enterprise Linux AS 3.0 Java: 1.5 Can somebody help me regarding the same. Regards, Kiran Tadepalli The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments. WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email. www.wipro.com -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Basic modjk + ssl + tomcat question
Because ssl only works through https:// You should really split that up though Bill Barker wrote: "Ed" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Hi! (modjk newbie) I'm using a modjk+SSL config (I did not make myself) that is mapped to a single worker. Behind, a single AJP connector recieves everything. The question is : how do I know from my webapp that a request is using SSL or not. Httpd/IIS/SunOne sends this information to Tomcat as part of the AJP/1.3 protocol. As a result, you can just use: if(request.isSecure()) { // SSL processing } else { // non-SSL processing } I saw the "secure" configuration attribute to the connector, and this leads me to think I actually need 2 AJP connectors (one for each case) and thus 2 workers. Am I wrong? * What's the right way of discriminating SSL and non-SSL requests within my webapp ? Do I need to change my current Apache/modjk config? Nope, the "secure" configuration attribute is ignored by the AJP/1.3 connector (which causes a few complaints ;-). Any advice welcome :) cheers - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat + Linux Server + Jasper Reports problem
Why not just set the environment variable to wherever the reports are expected to be produced. In other words, if it is the macine you are on, use "unix:0.0" if it is another machine, get ip of that machine and set the DISPLAY variable to "whateverip:0.0" that is providing there is an XServer running on that box. � wrote: the Anyone? On 2/7/06, Let�cia �lvares Barbalho <[EMAIL PROTECTED]> wrote: Hello everyone, I developed my webapp using netbeans and its embedded tomcat. I did some reports in jasper reports and they were working just fine with the embedded tomcat. Then, I moved my app to the tomcat directory in the server (which is the same machine) and the reports stopped working. They don't work locally in the server and they don't work when accessing the app from any other client machine (being linux or windows). At first, I was getting the following error: java.lang.InternalError: Can't connect to X11 window server using ':0.0 ' as the value of the DISPLAY variable. sun.awt.X11GraphicsEnvironment.initDisplay(Native Method) sun.awt.X11GraphicsEnvironment.(X11GraphicsEnvironment.java:134) java.lang.Class.forName0(Native Method) java.lang.Class.forName(Class.java:141) java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:62) Through google I found out that I should use the catalina.sh file to set: JAVA_OPTS="-Djava.awt.headless=true" I did it, but it did not solve the problem. It changed the error. Now I have: java.awt.HeadlessException java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121) java.awt.Window.(Window.java:274) java.awt.Frame.(Frame.java:401) java.awt.Frame .(Frame.java:366) javax.swing.JFrame.(JFrame.java:154) net.sf.jasperreports.view.JasperViewer.(JasperViewer.java:144) I tried google, but couldn't find a solution for it. Can someone help, please? Other important data about my server: leticia:/home/leticia # java -version java version "1.4.2_06" Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_06-b03) Java HotSpot(TM) Client VM (build 1.4.2_06-b03, mixed mode) leticia:/home/leticia # echo $JAVA_HOME /usr/lib/jvm/java leticia:/home/leticia # echo $PATH /usr/sbin:/bin:/usr/bin:/sbin:/usr/X11R6/bin Since it's working fine in the netbeans embedded tomcat and not in my linux server tomcat, I suppose the problem is in tomcat configuration. Both tomcat's are in the same computer. Any help is appreciated Thanks -- Let�cia �lvares Barbalho [EMAIL PROTECTED] -- Let�cia �lvares Barbalho [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with setting up an SSL secure page
What firewall are you using..if any? Is it on or off? Parsons Technical Services wrote: What is in the logs? - Original Message - From: "Mark Whitby" <[EMAIL PROTECTED]> To: Sent: Wednesday, February 08, 2006 11:02 AM Subject: Problem with setting up an SSL secure page Dear all, I am currently designing a final year project for my University course and I am having problems getting a working SSL connection. I have Tomcat set up and working fine, but when it comes to accessing a page over the https setup, I am having no luck. Firstly a few technical details. I am using Windows XP Home, with Internet Explorer 6.0.2900.2180. I am using the latest Java installation, jdk 1.5.0_05 and so the JSSE comes installed with that. I'm using Tomcat 5.0, the latest installation available (it's only been installed on my system for the last few weeks). I have McAffe Security Centre installed but the problem occurs even with this turned off. Now the problem. I have followed word by word the set up instructions in the Tomcat manual. I have created the certificate and verified it using the command line. I have altered the server.xml file to include the path "keystorePath="D:/FYPCode/keystore" "where I have copied the keystore to. I've done everything. Yet when I type https://localhost:8443 in the browser window I get nothing. When using IE it takes ages to search for the page, then eventually I get "This page cannot be displayed" and in Mozilla I get a message after a couple of minutes saying the page has timed out and get left with a blank page. So I can't load the page up at all. I've tried everything I can think of to get it to work. I have 3 different books on this subject and I've followed the instructions in every one to try and get this to work. Nothing has worked. I did a Google search using as many different combinations of words I can think of but the only help I get is for Tomcat 3 and the old JSSE installation. So I'm lost. I did even think about installing the JSSE 1.3 to see if that had an effect, as I can't find any of the jar files that are mentionned in that area. However, I felt it best to ignore that as it says. So as you can see I've tried everything I can think of. Nothing as worked. If anyone can help me I would be extremely grateful. Many thanks Mark Whitby [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Help me
Setting a classpath will not work as tomcat doesn't use it. At least that is what I have read and experienced. putting you stuff in the CLASSPATH tomcat uses is a more likely scenario. On my system I can only find it in one place: /usr/local/server/webapps/manager/WEB-INF/lib/commons-fileupload-1.0.jar Do you have the manager app installed? Mir Kasim Ali wrote: I am getting following error * org.apache.jasper.JasperException: Unable to compile class for JSP Generated servlet error: Only a type can be imported. org.apache.commons.fileupload.DiskFileUpload resolves to a package Generated servlet error: Only a type can be imported. org.apache.commons.fileupload.FileItem resolves to a package An error occurred at line: 12 in the jsp file: /ProcessFileUpload.jsp Generated servlet error: DiskFileUpload cannot be resolved to a type An error occurred at line: 12 in the jsp file: /ProcessFileUpload.jsp Generated servlet error: DiskFileUpload cannot be resolved to a type An error occurred at line: 12 in the jsp file: /ProcessFileUpload.jsp Generated servlet error: FileItem cannot be resolved to a type An error occurred at line: 12 in the jsp file: /ProcessFileUpload.jsp Generated servlet error: FileItem cannot be resolved to a type WHEN I AM COMPILING THE A JSP FILE(REQESTING THE JSP FILE THROUGH BROWSER) IN JSP I IMPORTED FOLLOWINGS <%@ page import="org.apache.commons.fileupload.DiskFileUpload"%> <%@ page import="org.apache.commons.fileupload.FileItem"%> <%@ page import="java.util.List"%> <%@ page import="java.util.Iterator"%> <%@ page import="java.io.File"%> sO PLEASE HELP ME TO GET IT WORK.IS THIS ERROR IS DUE TO CLASS PATH.IF YES THEN PLS SUGGEST ME WHAT PATH I SET FOR IT -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with Tomcat and Java versions
I have been looking at this for a couple of days, and it seems that maybe, it is a problem with the init.d startup. Sounds like it is pointing at the old tomcat and not the new until you run it manually and tell it tomcat 5. I am no systems person and I have many problems of this nature and it usually ends up being some file or symlink the I failed to remove or change with the new installation. Letícia Álvares Barbalho wrote: I think I could require that, but as a last try - if nothing else would work... But I really think this should be able to be solved without reinstalling. The thing is that when I only restart tomcat (with /etc/init.d/tomcat5 restart) things start working fine! So i don't think it's a tomcat problem, but a tomcat configuration problem. It means that maybe, even if reinstalling it, it would remain. On 2/10/06, Anoop kumar V <[EMAIL PROTECTED]> wrote: Do you have the option of reinstalling Tomcat5 - so that Tomcat5 would just pick up java 5 and not have anything at all to do with java 1.4?? -Anoop On 2/9/06, Let?cia ?lvares Barbalho <[EMAIL PROTECTED]> wrote: Hey, First of all thank you very much for the attention. I got some reading about it and found the jars [jaxp_parser_impl].jar and [xml-commons-apis].jar under /usr/share/tomcat5/common/endorsed I renamed them (so they could not be found) and restarted the server (the computer, I mean). Still, didn't work. The problem remains just as it was before :( On 2/9/06, Caldarale, Charles R <[EMAIL PROTECTED]> wrote: From: Let?cia ?lvares Barbalho [mailto:[EMAIL PROTECTED] Subject: Problem with Tomcat and Java versions I was using java 1.4.2 here, and recently migrated to java 1.5. Unfortunately, something probably is missing, 'cause I'm having problems with Tomcat. You don't say what Tomcat version you're using. If you were running 5.5.xon JRE 1.4.2, there may in fact be something extra, not something missing. The compatibility package that's required for 1.4.2 execution should be removed when using JRE 5; the package consists of two jars in common/endorsed, and these should be deleted. Of course, this may or may not have anything to do with your problem, but it's something to try. - 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] -- Let?cia ?lvares Barbalho [EMAIL PROTECTED] -- Thanks and best regards, Anoop -- Let?cia ?lvares Barbalho [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat out of memory
At our company we bounce tomcat every morning via a cron job Burak "Y" wrote: Hi all; I have a web site where 200 users online at average...These user overload started in these days... Webpages seem to be loading sometimes then blank page comes(totaly blank no error messages)...I havent set any memory pool option on Tomcat or havent installed native software support of Tomcat... Please give me an idea in this situation...What must i do? thanks Burak YILMAZ - Yahoo! Autos. Looking for a sweet ride? Get pricing, reviews, & more on new and used cars. -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Getting directory in which app is deployed
have your external process use a script that points to the webdirectory or if you use servlets, set an init param in the web.xml or in server.xml set an environment variable: or set a session variable in a jsp Wojciech Ciesielski wrote: Hi there, I have one problem... We have to execute external Java process from JAR archive included in our web application directory. The problem is, that all system dependant functions are relative to tomcat home directory. And - when our application is deployed outside tomcat directory via server.xml context definition - we cannot find a way to get path to our web directory... I am not sure if I am expressing myself clear, so example... I have web app with structure: someDir/web: WEB-INF META-INF dirWithArchive externalProgram.jar ... which is deployed OUTSIDE tomcat. I need to execute such code: Process = new ProcessBuilder("java -jar some/path/to/someDir/web/dirWithArchive/externalProgram.jar".split("\\s+").start(); from within struts action or struts plugin. HOW can I find a path without specifying it manualy (it's problematic because of different environments we deploy our application to). TIA Wojciech Ciesielski Software Mind | Where Quality Meets the Future mailto:[EMAIL PROTECTED] tel./fax: +48-12 6145170 http://www.softwaremind.pl -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problems with iso-8859-2 characters sending with GET method
why would you use 8859-2? why not use utf-8 and solve a lot of future problems? Przemysław Klein wrote: Hi All. I use iso-8859-2 character encoding in my application. When I sent forms using GET metod I receive question marks instead of some iso-8859-2 characters. There is no problem when I send same form with same data using POST metdod - all letters look properly. I set proper character set both for response and request. Any suggerstions (Tomcat 5.5.12)? Thanks in advance, Przemek - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Robots cannot read JSP?
Scott, Your assessment is incorrect! First off, curl doesn't read html pages, it does a get or post to a url just as though you clicked it in your browser (and a lot of other things you can do with curl). Second off, it is not the jsp that is the problem, it is the javascript as Tim said, and the lack of links. Mike David Smith wrote: I doubt the problem is with curl not being able to read files other than .htm or .html. The problem is only browsers execute javascript. Think of curl or the search engines as a browser without javascript enabled. What would you get in IE or Firefox if you disabled javascript? -- David Scott Purcell wrote: Tim, Thanks a lot for the info. I got to thinking, and tried invoking curl from my box on the url, and see exactly what you saw. The js screwing things up. So I decided to run curl on different pages, and I came to the conclusion that only htm, or html pages show up via curl? Does anyone think that the robots are just like curl, and that they can only read HTML files? Thanks for all, I know this is a bit off topic ...and I hope I don't hack anyone off. Thanks Scott -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: Friday, February 10, 2006 8:50 PM To: Tomcat Users List Subject: Re: Access log to see where robots go. The problem is your home page, not robots.txt. When / is requested - the following is served back, notice the javascript redirect: (the full file is below) function invokeWebApp() { top.location.href = "http://www.theuniquepear.com/unique/index.jsp";; } Search engines do not execute javascript are there are no links on the page so search engines have no where to go. (Except someone else's site). As much as I detest SEO companies, you might find it helpful to search for one for some assistance. The Unique Pear | Unique Home Decor & Accessories decor, garden, lighting, bath and more."> jaqua bath products, candleholders"> //<!-- function invokeWebApp() { top.location.href = "<a rel="nofollow" href="http://www.theuniquepear.com/unique/index.jsp"">http://www.theuniquepear.com/unique/index.jsp"</a>;; } invokeWebApp(); // --> hello -Tim Scott Purcell wrote: I have had trouble getting search engines to see my site. I built it with struts, and use some tags from the index.html page to get business logic, to finally get to my page. The url is http://www.theuniquepear.com Anyway, upon talking to some co-workers, they suggested I watch my access log, so I can see what files they are indexing. I thought I had the access log turned on for the site, and see when someone hits my web site, but as far as the searchbots go, I only see this in my logs daily. $ cat localhost_access_log.2006-02-07.txt | less 67.15.16.30 - - [07/Feb/2006:03:44:55 -0600] "GET /robots.txt HTTP/1.0" 404 985 67.15.16.30 - - [07/Feb/2006:03:46:21 -0600] "GET / HTTP/1.0" 200 844 67.15.16.30 - - [07/Feb/2006:03:51:57 -0600] "GET /robots.txt HTTP/1.0" 404 985 62.114.208.233 - - [07/Feb/2006:03:52:42 -0600] "GET /unique/welcome.do?OVRAW=home%20decorating%20ideas&OVKEY=home 62.114.208.233 - - [07/Feb/2006:03:52:44 -0600] "GET /unique/includes/siteWide.css HTTP/1.1" 200 15402 62.114.208.233 - - [07/Feb/2006:03:52:44 -0600] "GET /unique/images/header_pear.jpg HTTP/1.1" 200 11227 I see the entry for robots.txt, but I have no idea where they are going, or what they are doing. I turned on access log like this in the server.xml like so: suffix=".txt" pattern="common" resolveHosts="false"/> And that is a snippet of the log from above. - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.Object cannot be resolved
Do you have JAVA_HOME set in the catalina.sh or setenv.sh which it includes if it is there, in other words have you told tomcat specifically in one of its startup shells where your JAVA_HOME is? Sebastian Funk wrote: Hi Martin, I reinstalled JDK as well as JRE and both didn't change neither $CLASSPATH nor $JAVA_HOME. I set $JAVA_HOME to /usr/lib/jdk, it's a link to /usr/lib/jdk1.5.0_05. But without rt.jar in -cp it doesn't work. My whole javac-line is: 'sudo javac -cp /home/tomcat/tomcat/common/lib/servlet-api.jar:/home/tomcat/mysql-connector-java-3.1.11-bin.jar:/usr/lib/jdk/jre/lib/rt.jar:.' On Feb 11, 2006, at 10:21 PM, Martin Gainty wrote: Good Afternoon Sebastian- *usually* the JDK/JRE install is supposed to do that for you But as I found this past week (even webapps that cost alot of money) installs sometimes dont always do the complete task I would re-install the JDK/JRE and let the install configure your initial CLASSPATH for you make sure $JAVA_HOME is set correctly (and exported) otherwise things like $JAVA_HOME/bin/java and setting $CLASSPATH=$JAVA_HOME/jre/lib/rt.jar:$CLASSPATH wont work Martin- - Original Message - From: "Sebastian Funk" <[EMAIL PROTECTED]> To: "Tomcat Users List" Sent: Saturday, February 11, 2006 4:05 PM Subject: Re: java.lang.Object cannot be resolved Hi, I never set $CLASSPATH, but when I call rt.jar via "javac -cp .../ rt.jar Servlet.java", it works fine. Should I set $CLASSPATH or is that enough? On Feb 11, 2006, at 9:49 PM, Martin Gainty wrote: Lets start with the easy stuff is $JAVA_HOME\lib\rt.jar on your $CLASSPATH ??? Martin- - Original Message - From: "David Smith" <[EMAIL PROTECTED]> To: "Tomcat Users List" Sent: Saturday, February 11, 2006 1:56 PM Subject: Re: java.lang.Object cannot be resolved Looks like the kind of weirdness that makes me think the JVM has become unstable. Have you tried to restart Tomcat? -- David Sebastian Funk wrote: On Feb 11, 2006, at 6:30 PM, Caldarale, Charles R wrote: From: Sebastian Funk [mailto:[EMAIL PROTECTED] Subject: java.lang.Object cannot be resolved import java.lang.Object; The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files Don't know why you're suddenly getting this message, but there's no reason to import java.lang.Object (or anything else from java.lang, for that matter). There is an implicit import of java.lang.* for all compilations (see Java language spec, section 7.5.5). - Chuck I get that message at the first import-statement. When I don't import java.lang.Object, then I get exactly the same, e.g.: 1. ERROR in Familie.java (at line 1) import javax.servlet.*; ^ The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files Any ideas? Greetings, Sebastian Funk - 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] - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: App will work on localhost but blank on client PC.
How does localhost resolve in that scenario...why not use the hostname or ip address Alexander Alekseev wrote: I have a 2K3 Server on our intranet running Trend InterScan Messaging Security Suite which uses Apache Tomcat. I can access this app on the server through http://localhost:8447/ just fine. But when we try to access this app through a client connected to the 2k3s, we get a blank page with no error message, just one line of characters: _ [1][1] We've searched through Trend's support for this product and they don't have any suggestions except to make sure the redirects from IIS are there, which they are. Beyond that, they barely even mention Tomcat, so does anyone have an idea what may be wrong? -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: context error
Then do that jacky wrote: > > hi, > When i add a Context in the server.xml, an error occurs: > > Apache Tomcat/4.1.31 > Catalina.start: LifecycleException: Context startup failed due to > previous errors > LifecycleException: Context startup failed due to previous errors > at > org.apache.catalina.core.StandardContext.start(StandardContext.java:3578) > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1141) > at org.apache.catalina.core.StandardHost.start(StandardHost.java:707) > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1141) > at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:316) > at > org.apache.catalina.core.StandardService.start(StandardService.java:450) > at org.apache.catalina.core.StandardServer.start(StandardServer.java:2143) > at org.apache.catalina.startup.Catalina.start(Catalina.java:463) > at org.apache.catalina.startup.Catalina.execute(Catalina.java:350) > at org.apache.catalina.startup.Catalina.process(Catalina.java:129) > 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:156) > Stopping service Tomcat-Standalone > Catalina.stop: LifecycleException: Coyote connector has not been started > LifecycleException: Coyote connector has not been started > at > org.apache.coyote.tomcat4.CoyoteConnector.stop(CoyoteConnector.java:1296) > at org.apache.catalina.core.StandardService.stop(StandardService.java:499) > at org.apache.catalina.core.StandardServer.stop(StandardServer.java:2178) > at org.apache.catalina.startup.Catalina.start(Catalina.java:494) > at org.apache.catalina.startup.Catalina.execute(Catalina.java:350) > at org.apache.catalina.startup.Catalina.process(Catalina.java:129) > 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:156) > > If i remove the added context, tomcat will start. > In fact, i rearrange the directories, i don't know if this will impact > on the Context. If i put all directories under $CATALINA_HOME, tomcat > will work well with the Context. > > $CATALINA_HOME/bin/ > shared/ > server/ > > $CATALINA_BASE/bin/ > conf/ > webapps/ > logs/ > work/ > > Context is as following: > > > Best Regards. > jacky > -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JNDI Datasource Problem
27;ve followed the example word >>> for >>> word and got the following error: >>> >>> javax.servlet.ServletException: Unable to get connection, DataSource >>> invalid: "org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot >>> create >>> JDBC driver of class '' for connect URL 'null'" >>> >>> I did a google search for this but only managed to find something on >>> the >>> NetBeans website which wasn't much help. I've edited the server.xml >>> file as stated, placed the relevent jar file >>> (mysql-connector-java-3.1.12-bin.jar) in the lib folder in my web >>> application and in the /common/lib folder in the Tomcat home folder >>> and >>> I've reset the server and I'm still getting the same problem. >>> >>> I'm using MySQL, database is called 'fyptest' and the table is called >>> 'testdata'. So where am I going wrong? >>> >>> Many thanks >>> >>> Mark Whitby >>> >>> Server.xml file: >>> >>> >>debug="5" reloadable="true" crossContext="true"> >>> >>> >> prefix="localhost_DBTest_log." suffix=".txt" >>> timestamp="true"/> >>> >>> >> auth="Container" >>> type="javax.sql.DataSource"/> >>> >>> >>> >>> factory >>> org.apache.commons.dbcp.BasicDataSourceFactory >>> >>> >>> >>> >>> maxActive >>> 100 >>> >>> >>> >>> >>> maxIdle >>> 30 >>> >>> >>> >>> >>> maxWait >>> 1 >>> >>> >>> >>> >>> username >>> javauser >>> >>> >>> password >>> pilks2 >>> >>> >>> >>> >>> >>> >>> driverClassName >>> com.mysql.jdbc.Driver >>> >>> >>> >>> >>> url >>> >>> jdbc:mysql://localhost:3306/fyptest?autoReconnect=true >>> >>> >>> >>> >>> web.xml file: >>> >>> >>> DB Connection >>> jdbc/TestDB >>> javax.sql.DataSource >>> Container >>> >>> >>> >>> >>> - >>> 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] - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5 Possible Context Question
Do you have the servlet definitions and mappings in the web.xml for the apps? Also remember (i think) seeing something about tomcat 5 not using the invoker servlet by default anymore. If that is true, it would need to be uncommented in the web.xml file in the conf directory Scott Purcell wrote: Running Tomcat 5.5.15 on Win 2000. Originally we were running Tomcat 4.x?. So in order to upgrade our administrator loaded 5.5.15 and copied (copied) the webapps from the 4.x to the 5.5.15. There are currently four sites running, and I can hit the index.html for each context. But I cannot invoke any of the servlets within the webapp. After checking the 4.x server.xml, I recalled that we put the context entries there for these four sites. But as I am reading the 5.5.15 docs, it looks like putting them there is frowned upon. I would like to try and get this resolved, and possibly someone ran into this same thing? Is a context entry required somewhere in order to fire up servlets? Thanks, -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.5 Possible Context Question
I saw the response from chuckif the invoker servlet is a security risk, and only the mappings need to be done, then that is the way you should do it. Mike Sabroff wrote: Do you have the servlet definitions and mappings in the web.xml for the apps? Also remember (i think) seeing something about tomcat 5 not using the invoker servlet by default anymore. If that is true, it would need to be uncommented in the web.xml file in the conf directory Scott Purcell wrote: Running Tomcat 5.5.15 on Win 2000. Originally we were running Tomcat 4.x?. So in order to upgrade our administrator loaded 5.5.15 and copied (copied) the webapps from the 4.x to the 5.5.15. There are currently four sites running, and I can hit the index.html for each context. But I cannot invoke any of the servlets within the webapp. After checking the 4.x server.xml, I recalled that we put the context entries there for these four sites. But as I am reading the 5.5.15 docs, it looks like putting them there is frowned upon. I would like to try and get this resolved, and possibly someone ran into this same thing? Is a context entry required somewhere in order to fire up servlets? Thanks, -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with jar files in Tomcat 5.X
Are your samples part of a package? If not, then they are assigned the default package and that may not be the same as the package assigned when they are in the classes directory. Use a package statement if you are not already. Devireddy, Nagendra Reddy (STSD) wrote: Hi , I have installed Tomcat 5.0 and trying to access the sample servlet examples. My directory structure is like this /webapps/sample is the directory where I have my files /webapps/sample/index.html /webapps/sample/WEB-INF/web.xml /webapps/sample/WEB-INF/lib/sample.jar When I try accessing index.html .. Its throwing classdefinationNotFound error .. But that class exists in the sample.jar But When I unjarred and kept all the classes under /webapps/sample/WEB-INF/classes/*.class Then its working perfectly fine .. Can some one please help me in resolving this issue .. Thanks in advance, Nagendra -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: jdbc tomcat
When I do this from a program or bean or servlet, i make the connection a true url: url="jdbc:mysql://localhost:3306/everycitizen?username=everyuser&password=%" I dont know if it is different in the server.xml as I have never tried this, but why should it be? I have been fooled by thinking logically b4 and I know that things are different in different setups, but it's worth a try, huh? Mike David McMinn wrote: I'm running Tomcat 5.5 and trying to do a very simple jdbc connection a single table. I have set up tomcat to run on port 8070 and the mysql database on the default 3306 port. It's the connection statement in the jsp that is blowing up - If I take that out, it works fine. I'm getting page not found or "Cannot create JDBC driver of class '' for connect URL 'null' ". Steps I have done 1) Created a DB called everycitizen and a table called test with a column called pk. Created user everyuser w/ a password and granted Select privileges to that user. 2) Copied the mysql-connector-java-3.1.12-bin.jar into $CATALINA_HOME/common/lib. 3)Added the following to the $CATALINA_HOME/conf/server.xml javax.sql.Datasource" name="jdbc/WroxTC5" driverClassName="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost:3306/everycitizen" username="everyuser" password="%" maxActive="20" maxIdle="3" maxWait="100"/> 4) Added the following to the $CATALINA_HOME/webapps/jsp-examples/WEB-INF web.xml file at the bottom just before the entry after the last env-entry. jdbc/WroxTC5 javax.sql.DataSource Container 5) Added the JDBCTest.jsp file and the errorpg.jsp file to $CATALINA_HOME/webapps/jsp-examples/wroxjdbc directory. I created the wroxjdbc folder. The JDBC Test is: import="java.sql.*, javax.sql.*, java.io.*, javax.naming.InitialContext, javax.naming.Context" %> JDBC JNDI Resource Test InitialContext initCtx = new InitialContext(); DataSource ds = (DataSource)initCtx.lookup("java:comp/env/jdbc/WroxTC5"); Connection conn = ds.getConnection(); Statement stmt = conn.createStatement(); ResultSet rset = stmt.executeQuery("select * from test;"); %> while (rset.next()) { %> rset.close(); stmt.close(); conn.close(); initCtx.close(); %> -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cannot create JDBC driver of class '' for connect URL 'null'
Isn't that the old mysql driver?? I thought the new one is: org.gjt.mm.mysql.Driver or do I have it backwards? David McMinn wrote: Tomcat Server 5.5.15 - I searched for solutions and most mention a Context element in the server.xml. I only have a DefaultContext tag within with I have my resouce tag: url="jdbc:mysql://localhost:3306/everycitizen?autoReconnect=true" username="everyuser" /> The actual failure is on the connection = ds.getConnection(); line in the jsp if that helps any. SEVERE: Servlet.service() for servlet jsp threw exception org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null' at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:780) at org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:540) at org.apache.jsp.wroxjdbc.JDBCTest_jsp._jspService(org.apache.jsp.wroxjdbc.JDBCTest_jsp:83) 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:332) 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:639) at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1203) at java.lang.Thread.run(Unknown Source) Caused by: java.sql.SQLException: No suitable driver at java.sql.DriverManager.getDriver(Unknown Source) at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:773) ... 21 more -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Linux JNI ClassLoad
I "think" that this can be done with the environment variable "LD_LIBRARY_PATH" which will point to your C object file. This is an uneducated guess, but worth a try. Mike Shannon Scott wrote: Greetings, I have been trying to use some Native C code in one of my applications. I have it working, but after it runs once it fails. The release-notes mention that: "To avoid this problem, place classes that load native libraries outside of the web application, and ensure that the loadLibrary() call is executed only once during the lifetime of a particular JVM." From here: http://tomcat.apache.org/tomcat-5.0-doc/class-loader-howto.html I read: "For classes and resources that must be shared across all web applications, place unpacked classes and resources under $CATALINA_BASE/shared/classes, or place JAR files containing those classes and resources under $CATALINA_BASE/shared/lib." When I place class files into my $CATALINA_BASE/shared/classes, I get the 'NoClassDefFoundError' error. I have also tried a package in $CATALINA_BASE/shared/lib. Has anyone successfully resolved this issue on the Linux platform? Where is the config that tells tomcat to load classes from $CATALINA_BASE/shared/classes? It seems like mine is not configured correctly because they don't seem to get loaded. Any pointers or advice is greatly appreciated. Take care. S - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can TOMCAT cache the file in element?
You should use <%@ include file="other.jsp" %> instead of The jsp:include is for dynamic content that changes a lot, the @ include file is for static content and will get you closer to where you want to be. as far as cacheing goes, I am not knowledgeable enough to answer that question reliably. Mike Xuekun Hu wrote: Hi, I'm a newbie of TOMCAT 5.5. I have some jsp scripts which inlucde some static files by using element. I want to cache them to improve the performance. Can TOMCAT do that? If yes, how? I searched the docs, and found an attribute "cachingAllowed" in context container. Does the attribute work for element? Thanks in advance. Thx, Xuekun - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Trace messages when connecting to the database (MySql)
I am not sure if this is a Tomcat issue or a MySql issue. I get these trace messages in catalina.out: Wed Mar 08 07:48:48 CST 2006 TRACE: about 800 to 1000 lines of them, each time I connect to the database. I have googled and searched but can find nothing on the cause or the solution except maybe to use log4j. Any help would be appreciated. Tanks, Mike -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
TRACE messages
I am not sure if this is a Tomcat issue or a MySql issue. I get these trace messages in catalina.out: Wed Mar 08 07:48:48 CST 2006 TRACE: about 800 to 1000 lines of them, each time I connect to the database. I have googled and searched but can find nothing on the cause or the solution except maybe to use log4j. I have several versions of Tomcat 4.x / 5.x and it happens in all cases I don't really think it is a Tomcat issue, but was hoping someone else has experienced the problem and could lead me in the right direction. Any help would be appreciated. Thanks, Mike -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Disappointed
I have read and sometimes participated in these postings and answers in hopes of either finding answers to problems I am having or might have in the future and found it a well organized and contained group. I am disappointed though, in that I have posted a question in hopes of help with a problem I am experiencing and notta zilch zap. No response of any kind. So I posted it again and whappo, forget you. No answer. Is it common to have to post several times before getting a response? Is there a time delay because of the numerous amounts of threads? Is it something I did? I see a lot of really dumb things going through the postings and most of the time I try to remember that I once new nothing of Tomcat too, and that I still don't know very much and that no question is too dumb. Is my question too dumb? Have I been Black-Listed because I had a cruel response on one of those days that I just couldn't hold it back anymore? WASSUP??? Mike -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Disappointed
Thanks for the responses to this post! And by the way, funny how I got answers to my original post after posting this...amaizing, and I am truly sincere in thanking you for the link. http://www.catb.org/~esr/faqs/smart-questions.html good stuff! Mike Leon Rosenberg wrote: On 3/9/06, Frank W. Zammetti <[EMAIL PROTECTED]> wrote: Hehe, thanks for boiling my response down to a single line Leon! :) LOL You're welcome :-) saw the post, pasted the link, hit reply. If I'd had language skills so far developed as yours I would probably write the long explanation lines too. But my skills are far beyond yours, so I just throwed in the link :-) Frank Leon - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TRACE messages
Thanks Dave, I will scour my webapps to see if this is true, since I do have some common jars to all my webapps Mike David Smith wrote: Given the extreme lack of any info to base a diagnosis on, I'd say you have a library in your webapp generating this to standard out. My MySQL install does not do this. --David Mike Sabroff wrote: I am not sure if this is a Tomcat issue or a MySql issue. I get these trace messages in catalina.out: Wed Mar 08 07:48:48 CST 2006 TRACE: about 800 to 1000 lines of them, each time I connect to the database. I have googled and searched but can find nothing on the cause or the solution except maybe to use log4j. I have several versions of Tomcat 4.x / 5.x and it happens in all cases I don't really think it is a Tomcat issue, but was hoping someone else has experienced the problem and could lead me in the right direction. Any help would be appreciated. Thanks, Mike - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TRACE messages
actually not using log4j, just thought it might be a way to redefine what I log. thx Antonio Petrelli wrote: Mike Sabroff ha scritto: I am not sure if this is a Tomcat issue or a MySql issue. I get these trace messages in catalina.out: Wed Mar 08 07:48:48 CST 2006 TRACE: about 800 to 1000 lines of them, each time I connect to the database. I have googled and searched but can find nothing on the cause or the solution except maybe to use log4j. If you are using log4j, maybe you put a "debug" level to your root logger. Put the correct logging level to the root logger (I suggest at least INFO) and your desired level to your own logger. Ciao Antonio - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat just died on our Production Server
This happens to us too, just noticed it in the log today. I will be looking into this as we are taking control of our servers in the next couple of weeks (currently out-sourcing network admin) Mike Tim Lucia wrote: Can't this exception be the result of the user hitting the STOP button, or simply closing the browser? I.e., this can happen all the time. Are you certain this is the exact cause of death? From the stack trace (unless you've filtered it) it appears your code is complete, and the response is committed, and that Tomcat is now forwarding back through JK to Apache. So, I'm not sure your application can catch it. I.e., you've got no code on the stack which could even have a catch { ... } block. Or am I missing something? Tim -Original Message- From: Robert Harper [mailto:[EMAIL PROTECTED] Sent: Thursday, March 09, 2006 12:19 PM To: 'Tomcat Users List' Subject: RE: Tomcat just died on our Production Server It looks like the socket closed for some reason. You might want to try catching the exception and doing some clean up so that your app doesn't die. The connection is lost but you may be able to recover so that you can keep servicing requests from other connections. One way to test this would be to use your development server to service the same requests and while it is busy servicing a request, disconnect the network and see what happens to you app. The connection will be dead of course but your app should be coded so that it can recover and not need a restart so that when the connection is back, your app is ready to service more requests. Robert S. Harper Information Access Technology, Inc. -Original Message- From: Pete Alvin [mailto:[EMAIL PROTECTED] Sent: Thursday, March 09, 2006 10:08 AM To: users@tomcat.apache.org Subject: Tomcat just died on our Production Server Any idea what this means? At 1:52 our Tomcat just stopped serving pages. Help.. my boss is *pissed* and I have no idea how to address this. I re-started Tomcat and I'm back in service... but WHY DID IT HAPPEN? Thanks in advance. Pete Mar 9, 2006 1:52:12 AM org.apache.jk.core.MsgContext action WARNING: Error sending end packet java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:508) at org.apache.jk.common.JkInputStream.endMessage(JkInputStream.java:112) at org.apache.jk.core.MsgContext.action(MsgContext.java:293) at org.apache.coyote.Response.action(Response.java:182) at org.apache.coyote.Response.finish(Response.java:304) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:204) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:282) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:744) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.jav a:674) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocke t.java:866) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPo ol.java:684) at java.lang.Thread.run(Thread.java:534) Mar 9, 2006 1:52:12 AM org.apache.jk.common.ChannelSocket processConnection WARNING: processCallbacks status 2 - 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] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TRACE messages
Just in case someone else comes across this error, I found this code in the mysql connectorj Jdk14Logger.java: private void logInternal(int level, Object msg, Throwable exception) { StringBuffer msgBuf = new StringBuffer(); msgBuf.append(new Date().toString()); msgBuf.append(" "); switch (level) {case FATAL: msgBuf.append("FATAL: "); break; case ERROR: msgBuf.append("ERROR: "); break; case WARN: msgBuf.append("WARN: "); break; case INFO: msgBuf.append("INFO: "); break; case DEBUG: msgBuf.append("DEBUG: "); break; case TRACE: msgBuf.append("TRACE: "); break; } So..whoever said it was something in my webapps was right. Mike Sabroff wrote: I am not sure if this is a Tomcat issue or a MySql issue. I get these trace messages in catalina.out: Wed Mar 08 07:48:48 CST 2006 TRACE: about 800 to 1000 lines of them, each time I connect to the database. I have googled and searched but can find nothing on the cause or the solution except maybe to use log4j. I have several versions of Tomcat 4.x / 5.x and it happens in all cases I don't really think it is a Tomcat issue, but was hoping someone else has experienced the problem and could lead me in the right direction. Any help would be appreciated. Thanks, Mike -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Undeploy
Undeploy should really say "Remove" or "Delete" because that is what it does. It removes the webapp from disk!!! Lucky for you, permissions won't allow that. Mike P.S. I found out the hard way Artamonov, Juri wrote: Hi All, I have Tomcat 4.1.29 installed and I tried to used manager's undeploy command but this is doesn't work saying "Cannot remove document base for path ...". I know and I see in the archive that a lot of dicussions was here on mailing list but I still not sure if this bug or limitatiomn or it's fixed. Could you please tell me if this fixed and for what version in Tomcat4x? Thanks in advance, Juri. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TRACE messages
Well, I know you are all sitting on the edge of your chairs waiting for the solution to this... 2 make a long story short: Failure to thoroughly search the documentation led me to install a "DEBUG" version of connectorj. The tarball has 2 connectorj jar files, one which is a debug version and in my haste, i used the wrong one. No wonder no one else ever saw this problem! I must be the dumbest guy in the world since I am the only one who ever had this happen. Thanks, and I hope I didn't waste anybody's time Mike Mike Sabroff wrote: Just in case someone else comes across this error, I found this code in the mysql connectorj Jdk14Logger.java: private void logInternal(int level, Object msg, Throwable exception) { StringBuffer msgBuf = new StringBuffer(); msgBuf.append(new Date().toString()); msgBuf.append(" "); switch (level) {case FATAL: msgBuf.append("FATAL: "); break; case ERROR: msgBuf.append("ERROR: "); break; case WARN: msgBuf.append("WARN: "); break; case INFO: msgBuf.append("INFO: "); break; case DEBUG: msgBuf.append("DEBUG: "); break; case TRACE: msgBuf.append("TRACE: "); break; } So..whoever said it was something in my webapps was right. Mike Sabroff wrote: I am not sure if this is a Tomcat issue or a MySql issue. I get these trace messages in catalina.out: Wed Mar 08 07:48:48 CST 2006 TRACE: about 800 to 1000 lines of them, each time I connect to the database. I have googled and searched but can find nothing on the cause or the solution except maybe to use log4j. I have several versions of Tomcat 4.x / 5.x and it happens in all cases I don't really think it is a Tomcat issue, but was hoping someone else has experienced the problem and could lead me in the right direction. Any help would be appreciated. Thanks, Mike -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Undeploy
it does work. my answer is that whoever tomcat is running as does not have the permissions to remove or "Undeploy" the webapp. could be owner permissions, or if you are on windows it could be a protected archive or however windows does that sort of thing. Mike - :-) Artamonov, Juri wrote: I don't see answer in your sentence. What I need to use removeinstead of undeploy? This is a bug, this is limitation, what is it, that undeploy doesn't work for Tomcat 4x although documentation said that undeploy is used for ndeploying applications? -Original Message- From: Mike Sabroff [mailto:[EMAIL PROTECTED] Sent: Friday, March 10, 2006 6:37 PM To: Tomcat Users List Subject: Re: Undeploy Undeploy should really say "Remove" or "Delete" because that is what it does. It removes the webapp from disk!!! Lucky for you, permissions won't allow that. Mike P.S. I found out the hard way Artamonov, Juri wrote: Hi All, I have Tomcat 4.1.29 installed and I tried to used manager's undeploy command but this is doesn't work saying "Cannot remove document base for path ...". I know and I see in the archive that a lot of dicussions was here on mailing list but I still not sure if this bug or limitatiomn or it's fixed. Could you please tell me if this fixed and for what version in Tomcat4x? Thanks in advance, Juri. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Classloader question
SHORTCUT! Fran Varin wrote: aah...now I understand the reason it sounded foreign to me. We are a Windows shop so, I'm not sure we have the same capability. -- View this message in context: http://www.nabble.com/Classloader-question-t1332679.html#a3573581 Sent from the Tomcat - User forum at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Classloader question
I run cygwin (a linux like application/environment) on my windows box at home. When I create a symbolic link in that system and look at it frm the windows side of it, it IS a shortcut. try itI think it may work, but I am not sure that tomcat will see it as cygwin does. Curious. Fran Varin wrote: ...as in Windows shortcut...I'll have to look into that possibility. -- View this message in context: http://www.nabble.com/Classloader-question-t1332679.html#a3573968 Sent from the Tomcat - User forum at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: InputBuffer and Posting Data
This IS a java question. If post.Conn is a URLConnection you opened from the applet (looks that way) then you need to call setDoInput() and setDoOutput() methods (basically read/write) to make it a post. There is also a setUseCaches() (true or false) to control caching, default is true (reload button). Most of my statement is from the Javadocs. Vikram Goyal wrote: Hi all, I am trying to post some data via an applet to a JSP running on Tomcat 5.5.16. In my applet code, I am setting the following: postConn.setRequestMethod("POST"); postConn.setRequestProperty("Content-Length", (buf.length) + ""); postConn.setRequestProperty("Content-Type", "application/octet-stream"); Now, on the server side, I am retrieving my actual data by using the ServletInputStream gathered from request.getInputStream() method. The connection also contains some query parameters, which I am retrieving on the server side using request.getParameter(). Now, irrespective of the size of the data that I post, the ServletInputStream is truncating the data to a size of 8K (for files greater than that size, smaller files are the received correctly). I understand, after going through the source code, that the Request class uses the InputBuffer class for reading from this stream and the default size of the buffer for this operation is 8K. However, I would have expected this buffer to grow, if the data was larger than this default, but this is not happening. Is there a setting to increase this buffer automatically that I need to set? Alternatively, is there a setting that I need to set that will set the default to a larger value? I have searched and searched and cannot find anything. Thanks, Vikram -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat, Security and RMI
I have not used RMI since '98 and I know it has gone through some changes since then. It use to be that RMIC created stubs and skeletons fore marshalling the data and class structure. (That is not the case anymore is it?) But, when I did this...even though the stub was on one side and th skeleton on the other, I had to have at least one of them on both client and server side in order for it to work. This is probably not helpful, but my point isis this a Tomcat problem or a java problem?? Mike S. Gary Pennington wrote: Hi, Environment: OS: Solaris 10 on client and server Java: java full version "1.5.0_06-b04" Tomcat: 5.5.15 I'm trying make one of my servlets act as an RMI client with an RMI server running on a different host. I have a problem though and I can't seem to make much progress, so maybe someone can help me. If I invoke Tomcat with the following additional options, I can make my servlet/RMI client deploy: -Djava.rmi.server.codebase="http://webserver/builds2/garypen/jars/jscmc.jar http://webserver/builds2/garypen/jars/jscma.jar"; The application executes fine until it tries to make an RMI call to the server which involves transferring an object from the client to the server. At this point, if I make sure that the client jar file is in my server's class path then everything works fine, since the server loads the local class definition. However, this is not ideal and I don't want to have to load client jar files on my server. Rather, I would like to use the RMI capability to load the class definition from my client. This is the problem I'm trying to solve. I modified my catalina policy file so that: //Gary's nasty hack to get round all security :) grant codeBase "file:${catalina.home}/webapps/repository/-" { permission java.security.AllPermission; }; You'll note that I'm trying to give every permisssion to my servlets. I'll fix this later and only give specific permissions. I'm just using this whilst I figure out what is going on. I start up my server with the -security option to make sure the policy file is used to set the security environment. However, when the call to the server is made, I get the following errors: Caused by: java.rmi.UnmarshalException: error unmarshalling arguments; nested exception is: java.lang.ClassNotFoundException: access to class loader denied Caused by: java.security.AccessControlException: access denied (java.io.FilePermission /home/garypen/dev/dist/apache-tomcat-5.5.15/webapps/repository/WEB-INF/classes/- read) (This is just a snippet of the full trace log, the rest appears to be fairly unhelpful detail.) So, this is a big puzzle to me. I'm giving everything under /webapps/repository all permissions and yet Tomcat is failing to load the class that I want to send to my RMI server because of a permissions problem. Has anyone got any idea what the problem could be? On a related note. When you modify a policy file and use the '-' sign to indicate all jars and classes under this codebase have the policies applied. Does this include jar files with different extensions, e.g. .war or .ear? It doesn't seem that it does at the moment, so I'm unpacking my .war files. Again, this is a bit unsatisfactory, so I'd rather not do this. How do I set policy against .war files? Thanks for any pointers, Gary -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multiple sessions being created with Tomcat Proxy and session is null
Do you have any mappings for your servlet in a web.xml? I have always mapped my servlets in my web.xml, then made a JkMount the same as that mapping i.e. http://java.sun.com/dtd/web-app_2_3.dtd";> admincontrol com.bla.servlet.AdminServlet 4 admincontrol /admincontrol/* then in httpd.conf JkMount /*.jsp local JkMount /webappname/* local JkMount /admincontrol/* local then when accessing through these mappings, the session is the same session The problem is, if you don't have some kind of mapping in apache to match a webapp class in tomcat apache will access the jsp though a session at "/" and the webapp servlet at /servlet or whatever so you have 2 different sessions Doing it the way I described, then accessing through the /webappname/main.jsp where the action of the form is /webappname/admincontrol insures using the same session. Now, there may be better ways of doing this as the support persons at tomcat would know better than me, but this works for me. The thing is (I believe this to be true) that if you don't create the correct mappings for both servers, you can get 2 different sessions as you have 2 different servers. After all, a session is a connection between a client and a server. [EMAIL PROTECTED] wrote: Greetings: I am looking for help with an issue that I cannot find the answer to on the web or list-archives. My issue is this: I use Tomcat 5.5 and jdk 1.5 on linux. 1)I have a custom jsp tag that puts string data in a Session attribute when the jsp page loads (via pageRequest.getSession().setAttribute("var",value). 2)The jsp page is a form that submits to data to a servlet. The servlet retrieves the data request.getSession().getAttribute("var") to compare it with data from another form field. Under normal deployement with tomcat running on port 8080 and the app at context /myapp (http://localhost:8080/myapp) the servlet is able to retrieve the "var" out of the session and read it. The problem-issue is when I setup the apache/tomcat proxy (http not modjk). When I access the application with Apache on port 80 through the proxy on port 8082 (http://myhost.localhost/myapp), the request.getSession().getAttribute("var") within the servlet returns null. When I access the application throgh the proxied port (http://myhost.localhost:8082/myapp) the session attribute is not null. Also, when I access the application through port 80, the Tomcat manager webapp reports double the amount of sessions being created. Here is the connector setting in sever.xml Here is the host setting in server.xml myhost.localhost.org Here is the apache virtual host proxy configuration: ServerName myhost.localhost DocumentRoot /usr/local/tomcat/myhost Options Indexes ProxyPass / http://myhost.localhost:8082/myhost/ ProxyPassReverse / http://myhost.localhost:8082/myhost/ Does anyone know what is going on here? any help is greatly appreciated. Thanks. Bill mail2web - Check your email from the web at http://mail2web.com/ . - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: getInputStream() fails intermittently
You need to bounce tomcat occasioally We server a lot of content and we bounce tomcat every morning. Might not need it that often, but better safe than sorry. We use tomcat 4.xx Ramadhenu, Giridhar (STSD) wrote: Hello, I am encountering IOException while getting input stream using getInputStream() method on URLConnection class while sending data to Tomcat. Error is pasted below. "XML Regular I/O Exception - while getting the input stream from http://12.34.56.78:80/myApp/servlet/com.myComp.xml.CollectorServlet | original message -> 2006-03-04 22:20:05.54 java.io.IOException: Server returned HTTP response code: 500 for URL: http://12.34.56.78:80/myApp/servlet/com.myComp.xml.CollectorServlet"; The problem occurs after continuous operation of Tomcat server for about one month. But server does not show any exception when client encounters this problem. Please find the client code below. URLConnection httpConnection = null; //Code to open connection to URL httpConnection.setDoOutput(true); httpConnection.setDoInput(true); httpConnection.setUseCaches(false); httpConnection.setRequestProperty("Content-Type", "text/xml;charset=UTF-8"); httpConnection.setRequestProperty("Authorization", authString); //Code to get the output stream outStream.write(..); outStream.flush(); outStream.close(); try { inStream = httpConnection.getInputStream(); } catch (IOException e) { String sMessage = "XML Regular I/O Exception - while getting the input stream from " + url.toString() + " | original message -> " + (e); throw new XMLExceptionIO(sMessage); } Thanks in advance. Giridhar. -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Does Tomcat provide support for PHP scripts
fraught operation?? A lot of people seem to have problems with this, but I have had few problems with it. A bit time consuming to set up initially, but there is enough documentation to do it fairly easily. I think that the reason there seems to be so many posts here is because some people are not willing to spend a reasonable amount of time in the process before posting fer help. Mike Peter Crowther wrote: From: Ikonne, Ike [mailto:[EMAIL PROTECTED] Does Tomcat provide support for php scripting language? Yes, you could build PHP as a CGI program and run it using Tomcat's CGI support, but this would be pretty slow. There is no facility that I know of to integrate PHP with Tomcat. Otherwise, as Markus suggests, run Apache, run PHP inside Apache and use a connector to link Apache and Tomcat. Be aware that connecting Apache and Tomcat seems to be a somewhat fraught operation! - Peter - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: getInputStream() fails intermittently
No, I don't have any links, or documentation that states this, only know that tomcat does run out of recources at times be it memory or other leaks or problems so in order to not have this happen at "critical" times, the decision was to bounce it very early every morning for the least impact on visitors. I use tomcat 5.5.12 at home, and though the only traffic there is my own private development, I have to do this occationally when things don't work as they should... Ramadhenu, Giridhar (STSD) wrote: Hello Mike Sabroff, Thanks for the information. This seems to be a good option. Any pointers to Apache Tomcat group documentation that recommends restart of Tomcat after some time period with recommendations for time periods would be of great help. Thanks. -Original Message- From: Mike Sabroff [mailto:[EMAIL PROTECTED] Sent: Friday, March 31, 2006 7:35 AM To: Tomcat Users List Subject: Re: getInputStream() fails intermittently You need to bounce tomcat occasioally We server a lot of content and we bounce tomcat every morning. Might not need it that often, but better safe than sorry. We use tomcat 4.xx Ramadhenu, Giridhar (STSD) wrote: Hello, I am encountering IOException while getting input stream using getInputStream() method on URLConnection class while sending data to Tomcat. Error is pasted below. "XML Regular I/O Exception - while getting the input stream from http://12.34.56.78:80/myApp/servlet/com.myComp.xml.CollectorServlet | original message -> 2006-03-04 22:20:05.54 java.io.IOException: Server returned HTTP response code: 500 for URL: http://12.34.56.78:80/myApp/servlet/com.myComp.xml.CollectorServlet"; The problem occurs after continuous operation of Tomcat server for about one month. But server does not show any exception when client encounters this problem. Please find the client code below. URLConnection httpConnection = null; //Code to open connection to URL httpConnection.setDoOutput(true); httpConnection.setDoInput(true); httpConnection.setUseCaches(false); httpConnection.setRequestProperty("Content-Type", "text/xml;charset=UTF-8"); httpConnection.setRequestProperty("Authorization", authString); //Code to get the output stream outStream.write(..); outStream.flush(); outStream.close(); try { inStream = httpConnection.getInputStream(); } catch (IOException e) { String sMessage = "XML Regular I/O Exception - while getting the input stream from " + url.toString() + " | original message -> " + (e); throw new XMLExceptionIO(sMessage); } Thanks in advance. Giridhar. -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What is the best way to send back a file as http response?
You can Kanishka Liyanage wrote: Why cannot you forward your response to the file URL if the file is available within the web application directory. response.sendRedirect("File Location"); Otherwise you can use the servlet output stream Good Luck -Kanishka --- Meryl Silverburgh <[EMAIL PROTECTED]> wrote: Hi all, Can you please tell me what is the best way to send back a file as http response in a Servlet? Should I use NIO? Or I just use the normal, open the file, read it a chuck at a time and write that to the servlet output stream? Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Help with filter affecting Chinese words in request parameters
So, what are the differences on the machines that have the problem vs the ones that don not?? roy tang wrote: Hi, I'm new to this list, hope someone here can help. :) We're developing a webapp that should be able to accept Chinese input. We also have a filter installed in the webapp for some auditing that we need to do per request that's processed. However, we've found that when we submit a form with Chinese inputs, the Chinese chars end up saved to the database as HTML-escaped entities. (i.e. 罢 or such). So we backtrace, and we find that removing the filter from web.xml fixes the problem. We debug through the doFilter() method of our filter, but we find that at the start of the method, request.getParameter("PARAM_NAME") already shows the input as HTML-escaped entities. The weird thing is, this doesn't happen on all our Tomcat installations...each of our developers has a local Tomcat running, and it only happens for one or two. But it also happens on our Test (QA) server, such that our testing team always encounters the problem. Is there any particular language or encoding setting that I should be checking? Thanks a lot :D Roy -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Setting up to use 443
run as root else nothing less than 1024 David Shaw wrote: I have troubled setting up server.xml to use port 443 - always report that "The page cannot be displayed" in IE. 8080 and 8443 works fine though. Using the same setting in server.xml and just changing the port to use 8443 instead of 443, I can access using https://localhost:8443. Any idea what I need to set in order to get 443 working? Thanks, David _ Don�t just search. Find. Check out the new MSN Search! http://search.msn.click-url.com/go/onm00200636ave/direct/01/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat and Sysdeo Eclipse Plugin
Sounds like a Sysdeo problem not tomcat Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 Asad Habib wrote: Hello. I am experiencing a problem trying to start Tomcat from Eclipse using the Sysdeo Plugin. The error I get is as follows: Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/catalina/startup/Bootstrap I am running Tomcat 5.5.16 and using Eclipse 3.1.2 with Sysdeo Eclipse Tomcat Plugin 3.1.0 on Mac OS X. I had no problems using this plugin with Tomcat 5.5.9. When I try starting Tomcat from the command line via the Terminal application, everything works. Also, I checked and the Bootstrap class does exist in the Tomcat bin directory. Any help would be appreciated. Thank you. - Asad - 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: User WEb Applications
You might try writing some script they can use that will create a symlink in the webapps directory to their home directory: #!/bin/csh # do whatever needed to write to directory and read or prompt for user directory # maybe some other logging or setup ??? cd /usr/local/tomcat/webapps #create symlink to userdir ln -s /home/user/dirname dirname #wait for tomcat to load sleep 10 exit Then tomcat will load this as a webapp providing ofcourse that the directory structure the link is pointing to is a true webapp (containing WEB-INF, WEB-INF/lib, WEB-INF/classes) directories Ofcourse, if you are using apache on port 80, and using jk, you will have to write a script to add the jk-mount as well Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 Darryl Miles wrote: Robert Frank wrote: I'm trying to set up the standalone server such that users can install and deply webapplications in their home directory (this is for a lab). Heh... Container stability during development for a single user is hard enough than to have to worry about what your other lab students are doing at the same time. The general get-out when you first find a problem that isn't an obvious programming error is to restart the container and re-test the situation. Maybe you'd be better off teaching students how to use Eclipse and manage their own Tomcat instance from within it. But to use Eclipse you'd need PCs of half decent spec with a little more RAM on board. Sorry I don't have an answer to your request, and whatever I do say has more bearing on TC 5.5.x than 5.0.x. But my understanding is that there is a single deployment directory folder per virtual hostname. So if you wanted to give each student/computer their own workspace maybe you could setup DNS to point lab01host001.tomcat.mydomain.com to the same IP address. Then setup directives in conf/server.xml like: appBase="/opt/website/lab01host001.tomcat.mydomain.com/tomcat/webapps" workDir="/opt/website/lab01host001.tomcat.mydomain.com/tomcat/work" unpackWARs="true" autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false"> To setup each lab users workspace use: mkdir /opt/website/lab01host001.tomcat.mydomain.com/tomcat mkdir /opt/website/lab01host001.tomcat.mydomain.com/tomcat/work mkdir /opt/website/lab01host001.tomcat.mydomain.com/tomcat/webapps # chown the "work" folder to the same user the TC JVM instance runs as: chown jakarta.jakarta /opt/website/lab01host001.tomcat.mydomain.com/tomcat/work chmod 775 /opt/website/lab01host001.tomcat.mydomain.com/tomcat/work # chown the "webapps" folder to the same user as the student that is allowed to deploy, but also give the TB JVM instalce group permission to write too. chown student0123.jakarta /opt/website/lab01host001.tomcat.mydomain.com/tomcat/webapps chmod 775 /opt/website/lab01host001.tomcat.mydomain.com/tomcat/webapps # deploy your webapp and access as: http://lab01host001.tomcat.mydomain.com/ cp ROOT.war /opt/website/lab01host001.tomcat.mydomain.com/tomcat/webapps/ROOT.war # or under a context and access as: http://lab01host001.tomcat.mydomain.com/student0123/ cp student0123.war /opt/website/lab01host001.tomcat.mydomain.com/tomcat/webapps/student0123.war # You may wish to create inside your WAR the file META-INF/context.xml for any context specific parameters. See TC documentation. You'd still need to give the students the ability to shutdown and restart the container themselves, it really is a necessary requirement to successfully develop with TC. More so if you are a student and don't understand anything to begin with and need to learn from making as many mistakes as possible. HTH Darryl Following the instructions of the documentation (for 5.0), I found the topic 'User Web Applications' in the host container documentation. The doc states: 'If a user home directory has been set up for a user named craigmcc, then its contents will be visible from a client browser by making a request to a URL like:' which is the behaviour I get. I.e., it will only list the contents of the directories and return files if selected. The doc then goes on: 'Successful use of this feature requires recognition of the following considerations: Each user web application will be deployed with characteristics established by any DefaultContext element you have configured for this Host.' Which tells me that user applications are *deployed* - but how? No matter what applictaion I put into the user's webapp directory (given as attribute to the Listener tag), it is never deployed, but if I put it into the webapp of the tomcat home, then it will be deployed. The logs state: catalina.out: 4-May-06 11:50:37 AM org.apache.catalina.startup.ContextConfig applicationC
Re: Context fails to load with Filter
442) at org.apache.catalina.core.StandardService.start( StandardService.java:450) at org.apache.catalina.core.StandardServer.start(StandardServer.java :683) at org.apache.catalina.startup.Catalina.start(Catalina.java:537) 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:585) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:271) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:409) May 9, 2006 11:46:33 AM org.apache.catalina.core.ApplicationContext log INFO: ContextListener: contextInitialized() May 9, 2006 11:46:33 AM org.apache.catalina.core.ApplicationContext log INFO: SessionListener: contextInitialized() May 9, 2006 11:46:34 AM org.apache.coyote.http11.Http11Protocol start INFO: Starting Coyote HTTP/1.1 on http-8080 May 9, 2006 11:46:34 AM org.apache.jk.common.ChannelSocket init INFO: JK: ajp13 listening on /0.0.0.0:8009 May 9, 2006 11:46:34 AM org.apache.jk.server.JkMain start INFO: Jk running ID=0 time=0/25 config=null May 9, 2006 11:46:34 AM org.apache.catalina.storeconfig.StoreLoader load INFO: Find registry server-registry.xml at classpath resource May 9, 2006 11:46:34 AM org.apache.catalina.startup.Catalina start INFO: Server startup in 2637 ms thanks for your help. -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Context fails to load with Filter
Disreguard my previous statement as I am obviously brain deadsorry Mike Sabroff wrote: If this is truly what your web.xml looks like, you are missing the end tag '>' in the following line com.affinity.tasc.filters.AuthenticateFilter Jason Beck wrote: Hello list, I have written my first filter and think that I have it right, but when I try to start Tomcat 5.5.9 after applying the necessary configuration changes to web.xml, the Context that the Filter is in fails to start. Perhaps someone can tell me what I may have done wrong. <-- web.xml --> AuthenticateFilter com.affinity.tasc.filters.AuthenticateFilter AuthenticateFilter Index Index com.affinity.tasc.core.Index Index /Index <-- end web.xml --> <-- Filter code --> package com.affinity.tasc.filters; import java.io.IOException; import javax.servlet.*; import javax.servlet.http.*; import com.affinity.tasc.beans.SiteUserBean; public abstract class AuthenticateFilter implements Filter { private FilterConfig fc; public void doFilter(ServletRequest req, ServletResponse res, FilterChain chain) throws IOException, ServletException { /* Make sure we are dealing with HTTP */ if (req instanceof HttpServletRequest) { HttpServletRequest request = (HttpServletRequest)req; HttpServletResponse response = (HttpServletResponse)res; HttpSession session = request.getSession(false); if (request.getParameter("Authenticate").equals("1")) { try { SiteUserBean user = new SiteUserBean(); user.setUsername( request.getParameter("username")); user.setPassword( request.getParameter("password")); int authed = user.getUserAuthed(); /* Successful authentication */ if (authed > 0) { session.setAttribute("user", user); } session.setAttribute("authed", authed); } catch (NullPointerException nx) { nx.printStackTrace(); } catch (Exception ex) { ex.printStackTrace(); } } } /* Continue filtering */ chain.doFilter(req, res); } public void init(FilterConfig filterConfig) throws ServletException { this.fc = filterConfig; } public void destroy() { this.fc = null; } } <-- end filter code --> Here is the output from catalina.out when I try to start tomcat with this filter installed... May 9, 2006 11:46:31 AM org.apache.coyote.http11.Http11Protocol init INFO: Initializing Coyote HTTP/1.1 on http-8080 May 9, 2006 11:46:31 AM org.apache.catalina.startup.Catalina load INFO: Initialization processed in 1270 ms May 9, 2006 11:46:32 AM org.apache.catalina.core.StandardService start INFO: Starting service Catalina May 9, 2006 11:46:32 AM org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/5.5.9 May 9, 2006 11:46:32 AM org.apache.catalina.core.StandardHost start INFO: XML validation disabled May 9, 2006 11:46:32 AM org.apache.catalina.core.StandardContext filterStart SEVERE: Exception starting filter AuthenticateFilter java.lang.InstantiationException at sun.reflect.InstantiationExceptionConstructorAccessorImpl.newInstance( InstantiationExceptionConstructorAccessorImpl.java:30) at java.lang.reflect.Constructor.newInstance(Constructor.java:494) at java.lang.Class.newInstance0(Class.java:350) at java.lang.Class.newInstance(Class.java:303) at org.apache.catalina.core.ApplicationFilterConfig.getFilter( ApplicationFilterConfig.java:212) at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef( ApplicationFilterConfig.java:308) at org.apache.catalina.core.ApplicationFilterConfig.( ApplicationFilterConfig.java:79) at org.apache.catalina.core.StandardContext.filterStart( StandardContext.java:3540) at org.apache.catalina.core.StandardContext.start( StandardContext.java:4110) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java :1012) at org.apache.catalina.core.StandardHost.start(StandardHost.java :718) at org.apache.catalina.core.ContainerBase.start(ContainerB
Re: tomcat ssl not working
I am running 5.5.9 and have no problems with it (except that it is expired) but it still works if I accept it. Mike AJ Jonen wrote: My tomcat server is not responding when I type in https://localhost:8443. oddly enough it does work when I type in http://localhost:8443 I'm having a bit of an issue getting Tomcat to work on the secure port 8443. What happens is I type https://localhost:8443 and the page never loads. I get no errors (page cannot be found, page cannot be displayed etc). My browser simply looks like it's loading the page, it eventually says that it's done, but my browser home page is still displayed. - The unsecure port (port 8090 in my case, because port 8080 was already in use) works fine. - I generated my keystore file, presumably correctly (I was prompted to enter my name, organization, location, etc), and it is in the correct location (C:\Program Files\Apache Software Foundation\Tomcat 5.5\conf). - Kathy O. looked at my server.xml page and says that everything looks correct. Everything looks right to me too. - I am using Tomcat 5.5 and I am using the correct java version (1.5, not 1.4). Any ideas on what might be preventing the page from loading correctly on the secure port? Rebecca - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JSP Compilation, Jasper class loading, and log4j issues
Looks like maybe some directory permissions changed or some system changed not allowing access to what Jasper needs Mike Sabroff Web Services Developer [EMAIL PROTECTED] 920-568-8379 -Original Message- From: David Rickard [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 18, 2005 12:03 PM To: users@tomcat.apache.org Subject: JSP Compilation, Jasper class loading, and log4j issues System: Solaris SunOS 5.9 Apache: 2.0.52 Tomcat: 4.1.29 Mod JK: 1.2.6 JDK: 1.4.2.02 We have used the above Apache-Tomcat installation for 1-2 years. Within the last few days, Tomcat has started failing to compile JSPs. When a JSP is modified (even simply touched), Tomcat throws the following error message: org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: -1 in the jsp file: null Generated servlet error: [javac] Compiling 1 source file Tomcat is otherwise behaving normally: unmodified pages load and behave normally. catalina.out is peppered with ClassNotFoundException messages for various jasper classes (org.apache.jasper.runtime.HttpJspBase, org.apache.jasper.runtime.TagHandlerPool, org.apache.jasper.servlet.JspServlet). The first sign of trouble came over the weekend, when the log-roller cron (logadm) started returning the following error messages: log4j:WARN No appenders could be found for logger (org.apache.commons.digester.Digester.sax). log4j:WARN Please initialize the log4j system properly. We do not use log4j in any applications on this server (is it used internally by Tomcat?). I would suspect corruption of the jasper JARs, except there is no sign they've been touched recently; these are the contents of the common/lib directory: -rw-r--r-- 1 root other 45386 Nov 21 2003 activation.jar -rw-r--r-- 1 root other 736810 Nov 21 2003 ant.jar -rw-r--r-- 1 root other 165119 Nov 21 2003 commons-collections.jar -rw-r--r-- 1 root other 100776 Nov 21 2003 commons-dbcp-1.1.jar -rw-r--r-- 1 root other 22327 Nov 21 2003 commons-logging-api.jar -rw-r--r-- 1 root other 39523 Nov 21 2003 commons-pool-1.1.jar -rw-r--r-- 1 root other 183104 Nov 21 2003 jasper-compiler.jar -rw-r--r-- 1 root other 72933 Nov 21 2003 jasper-runtime.jar -rw-r--r-- 1 root other 6727 Nov 21 2003 jdbc2_0-stdext.jar -rw-r--r-- 1 root other 98496 Nov 21 2003 jndi.jar -rw-r--r-- 1 root other 8674 Nov 21 2003 jta.jar -rw-r--r-- 1 root other 280984 Nov 21 2003 mail.jar -rw-r--r-- 1 root other 28520 Nov 21 2003 naming-common.jar -rw-r--r-- 1 root other 18245 Nov 21 2003 naming-factory.jar -rw-r--r-- 1 root other 38836 Nov 21 2003 naming-resources.jar -rw-r--r-- 1 root other 79265 Nov 21 2003 servlet.jar I've compared this directory with other (functioning normally) Tomcat installations here, and no JARs are missing. Any ideas what might be causing this, and how to fix it (short of reinstalling Tomcat)? -- David Rickard Software Engineer TechBooks/GTS Your Single Source Solution! Los Angeles CA * York, PA * Boston,MA * New Delhi, India Visit us on the World Wide Web <http://www.techbooks.com>http://www.techbooks.com [EMAIL PROTECTED] 5650 Jillson St., Los Angeles, CA 90040 (323) 888-8889 x331 (323) 888-1849 (Fax) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]