RE: blue screen with servlets/jsp in Apache-Tomcat
Are you useing ZoneAlarm? I noticed that vsdatant.sys (from ZoneAlarm) does not get along well with Tomcat (especially in combination with struts and UltraDev) causing a BSD. D -Original Message- From: Randy Layman [mailto:[EMAIL PROTECTED]] Sent: Tuesday, July 03, 2001 7:04 AM To: [EMAIL PROTECTED] Subject: RE: blue screen with servlets/jsp in Apache-Tomcat If it is a server problem I would suggest trying a different (1.2) JVM to rule that out. Also, I would stick with getting Tomcat standalone to work first. (Take little steps) Randy -Original Message- From: Dmitri Colebatch [mailto:[EMAIL PROTECTED]] Sent: Tuesday, July 03, 2001 2:46 AM To: [EMAIL PROTECTED] Subject: Re: blue screen with servlets/jsp in Apache-Tomcat What happens if you look at them from another box? that is - is it a client problem or a server problem? On Tue, 3 Jul 2001 16:07, you wrote: hi, i get the blue screen of death everytime i access a servlet or jsp example from the Tomcat examples with: http://localhost:8080/examples/jsp/* or http://localhost:8080/examples/servlet/* or http://localhost/examples/jsp/* or http://localhost/examples/servlet/* system: dell inspiron 4000 windows 2000 pro jdk 1.3.1 jakarta-tomcat 3.2.2 with jserv module loaded in apache i don't know where/how to start debugging this. i don't even get any runtime errors. please help. thanks, --meg __ Get your FREE personalized e-mail at http://www.canada.com
RE: JSP, JNI, classloader
I had many similar problems with JNI a while back. I don't remember all the details, but I remember that for some reason, any Java class that used JNI could NOT be in a package. I don't know if they ever provided a fix to this, but I removed all package info from my JNI related java files, and everything began to work. Good luck. D -Original Message- From: Matthew Lerner [mailto:[EMAIL PROTECTED]] Sent: Wednesday, June 20, 2001 4:41 PM To: [EMAIL PROTECTED] Subject: JSP, JNI, classloader Apologies for being a clueless newbie, but I've been beating my head on this for the last week. I'm setting up a new webapp. It needs to interact with a C++ library. (There are reasons it needs to be in C++. Really there are.) Since I've never done JSP or JNI before, I figured I'd get a skeletal application going - all I'm trying to do is have a .jsp page communicate with a C library. So first I thought I'd better set up a Java Bean and get my jsp talking to that, and then maybe I can see about talking to JNI. That first part went great. Since I'd had trouble with it before, I very carefully verified that recreating my .class file (in ROOT/WEB-INF/classes) actually modified my bean. I even managed to use both get and set methods. All was going well. Then I added the native interface code to the bean: public native int getInt(int arg); static { System.loadLibrary(hello); } I'd tested this code in a normal java application, and it worked fine. When I tried to load the Bean from JSP though, not only did it not work (I failed to copy the error message, sorry), but it stopped reloading the class when I recompile it. Restarting Tomcat did not help. So, first things first -- how do I get Tomcat to see new versions of the class? After that, anybody have pointers on how to get JSP to talk to JNI? Thanks in advance Matthew Lerner
RE: JSP, JNI, classloader
Nope. I even dug up my old files to make sure. Reviewing your origional message, and the first question; it appears that you may not have your class files in the right location. I had put my jsp files directly into the tomcatwebapps/ROOT directory, and the classes into tomcatwebapps/ROOT/WEB-INF/classes. You may be able to put them in your own directory in the webapps folder, but I didn't do that at the time. If this doesn't work, I'm fresh out of ideas for the time being. D -Original Message- From: Matthew Lerner [mailto:[EMAIL PROTECTED]] Sent: Wednesday, June 20, 2001 5:42 PM To: [EMAIL PROTECTED] Subject: RE: JSP, JNI, classloader Sadly, none of my classes are in a package. Are you sure it didn't go the other way? I could try and PUT them in packages... -Matthew At 05:33 PM 6/20/2001 -0400, you wrote: I had many similar problems with JNI a while back. I don't remember all the details, but I remember that for some reason, any Java class that used JNI could NOT be in a package. I don't know if they ever provided a fix to this, but I removed all package info from my JNI related java files, and everything began to work. Good luck. D -Original Message- From: Matthew Lerner [mailto:[EMAIL PROTECTED]] Sent: Wednesday, June 20, 2001 4:41 PM To: [EMAIL PROTECTED] Subject: JSP, JNI, classloader Apologies for being a clueless newbie, but I've been beating my head on this for the last week. I'm setting up a new webapp. It needs to interact with a C++ library. (There are reasons it needs to be in C++. Really there are.) Since I've never done JSP or JNI before, I figured I'd get a skeletal application going - all I'm trying to do is have a .jsp page communicate with a C library. So first I thought I'd better set up a Java Bean and get my jsp talking to that, and then maybe I can see about talking to JNI. That first part went great. Since I'd had trouble with it before, I very carefully verified that recreating my .class file (in ROOT/WEB-INF/classes) actually modified my bean. I even managed to use both get and set methods. All was going well. Then I added the native interface code to the bean: public native int getInt(int arg); static { System.loadLibrary(hello); } I'd tested this code in a normal java application, and it worked fine. When I tried to load the Bean from JSP though, not only did it not work (I failed to copy the error message, sorry), but it stopped reloading the class when I recompile it. Restarting Tomcat did not help. So, first things first -- how do I get Tomcat to see new versions of the class? After that, anybody have pointers on how to get JSP to talk to JNI? Thanks in advance Matthew Lerner
Thanks RE: Apache, Struts, .conf files
Thanks Dante! Your email made me realize that the struts instructions assume that your using JServ and not mod_jk D -Original Message- From: Dante le Poole [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 17, 2001 10:23 AM To: [EMAIL PROTECTED] Subject: RE: Apache, Struts, .conf files Replace the ApJServMount statements with JkMount statements in the generated tomcat-apache.conf file (and replace any other JServ statements with their mod_jk equivalents). That did it for me. Dante ::-Original Message- ::From: [EMAIL PROTECTED] ::[mailto:[EMAIL PROTECTED]]On ::Behalf Of DHarty ::Sent: Wednesday, May 16, 2001 5:43 PM ::To: [EMAIL PROTECTED] ::Subject: Apache, Struts, .conf files :: :: ::Help, :: ::I am trying to install the struts framework examples on my apache1.3.19 / ::tomcat3.2.1 setup. :: ::I have followed the directions included with struts (relevent instruction ::listed at end of email :: ::When I try to start the Apache service (tomcat is already running), I get an ::internal Windows NT error :: ::If I remove the :: :: include d:/web/apache_1.3.19/Apache/conf/tomcat-apache.conf :: ::line, apache starts, but does not recognize *.do files as appended to the ::modified tomcat-apache.conf file. :: ::I have tried skipping step 7 (modifiing the tomcat-apache.conf file) with ::the same result. :: ::I have also tried different iterations of removing, altering the line that ::referneces mod_jk: :: :: include d:/web/tomcat/conf/mod_jk.conf-auto :: ::ex: :: include d:/web/tomcat/conf/mod_jk.conf-auto ::d:/web/apache_1.3.19/Apache/conf/tomcat-apache.conf :: ::with and without the tomcat-apache.conf line. :: ::I have even tried pointing the include line to the origional (unmolested) ::tomcat-apache.conf file in the tomcat path. :: ::Please tell me I am missing something obvious. :: :: :: ::D :: ::Struts instructions: :: ::-- :: :: ::This document contains notes that have been accumulated on getting the ::Struts ::applications (documentation and example) running in a variety of servlet ::container environments. :: ::For most containers, you need only to: :: ::1: Copy the WAR files in your Struts /webapp directory to your ::containers :: webapps directory. :: ::2: In some cases, you may need to restart your container if it is running. :: :: ::* Tomcat 3.1+ with Apache - Additional steps provided below. :: :: ::TOMCAT 3.1 (OR LATER) WITH APACHE ::- :: ::* These instructions assume you have successfully integrated :: Tomcat with Apache according to the Tomcat documentation. :: ::3* Copy struts-documentation.war and struts-example.war :: to your $TOMCAT_HOME/webapps directory :: ::4* Restart Tomcat if it is already running :: ::5* Tomcat will generate a file $TOMCAT_HOME/conf/tomcat-apache.conf :: that will be used by Apache. This file is regenerated every time :: you start Tomcat, so copy this file to a safe place (such as :: your Apache configuration directory; on Unix systems this is usually :: /usr/local/apache/conf. :: :: (I SKIPPED STEP 6) ::6*If you are running Tomcat 3.1, Tomcat will not have generated the :: entries for your new applications. Add the following lines to the :: tomcat-apache.conf file that you have saved, replacing :: $TOMCAT_HOME with the path to your Tomcat home directory: :: ::Alias /struts-documentation ::$TOMCAT_HOME/webapps/struts-documentation ::Directory $TOMCAT_HOME/webapps/struts-documentation :: Options Indexes FollowSymLinks ::/Directory ::ApJServMount /struts-documentation/servlet /struts-documentation ::Location /struts-documentation/WEB-INF/ :: AllowOverride None :: deny from all ::/Location :: ::Alias /struts-example $TOMCAT_HOME/webapps/struts-example ::Directory $TOMCAT_HOME/webapps/struts-example :: Options Indexes FollowSymLinks ::/Directory ::ApJServMount /struts-example/servlet /struts-example ::Location /struts-example/WEB-INF/ :: AllowOverride None :: deny from all ::/Location :: ::7* On all versions of Tomcat, the generated file above does not :: know anything about extension mappings defined in a web.xml file, :: so the *.do URIs that go to the controller servlet will not be :: recognized. To fix this, add the following line to the saved :: version of tomcat-apache.conf, after the corresponding line :: for the .jsp extension: :: ::AddHandler jserv-servlet .do :: ::8* Ensure that the saved version of tomcat-apache.conf is referenced :: in your Apache httpd.conf configuration file. A typical use would :: have the following line at the bottom of httpd.conf: :: ::Include /usr/local/apache/conf/tomcat-apache.conf :: :: (I used: include d:/web/apache_1.3.19/Apache/conf/tomcat-apache.conf) :: ::9* In order to recognize index.jsp as a default page for web :: applications, search in your httpd.conf for a DirectoryIndex :: directive
apache-tomcat ftp
This may not be the right place for this, but does either apache or tomcat have built in ftp functionality. I've searched all over the place for mention of it, with no success. How would you set it up? D
Apache, Struts, .conf files
Help, I am trying to install the struts framework examples on my apache1.3.19 / tomcat3.2.1 setup. I have followed the directions included with struts (relevent instruction listed at end of email When I try to start the Apache service (tomcat is already running), I get an internal Windows NT error If I remove the include d:/web/apache_1.3.19/Apache/conf/tomcat-apache.conf line, apache starts, but does not recognize *.do files as appended to the modified tomcat-apache.conf file. I have tried skipping step 7 (modifiing the tomcat-apache.conf file) with the same result. I have also tried different iterations of removing, altering the line that referneces mod_jk: include d:/web/tomcat/conf/mod_jk.conf-auto ex: include d:/web/tomcat/conf/mod_jk.conf-auto d:/web/apache_1.3.19/Apache/conf/tomcat-apache.conf with and without the tomcat-apache.conf line. I have even tried pointing the include line to the origional (unmolested) tomcat-apache.conf file in the tomcat path. Please tell me I am missing something obvious. D Struts instructions: -- This document contains notes that have been accumulated on getting the Struts applications (documentation and example) running in a variety of servlet container environments. For most containers, you need only to: 1: Copy the WAR files in your Struts /webapp directory to your containers webapps directory. 2: In some cases, you may need to restart your container if it is running. * Tomcat 3.1+ with Apache - Additional steps provided below. TOMCAT 3.1 (OR LATER) WITH APACHE - * These instructions assume you have successfully integrated Tomcat with Apache according to the Tomcat documentation. 3* Copy struts-documentation.war and struts-example.war to your $TOMCAT_HOME/webapps directory 4* Restart Tomcat if it is already running 5* Tomcat will generate a file $TOMCAT_HOME/conf/tomcat-apache.conf that will be used by Apache. This file is regenerated every time you start Tomcat, so copy this file to a safe place (such as your Apache configuration directory; on Unix systems this is usually /usr/local/apache/conf. (I SKIPPED STEP 6) 6* If you are running Tomcat 3.1, Tomcat will not have generated the entries for your new applications. Add the following lines to the tomcat-apache.conf file that you have saved, replacing $TOMCAT_HOME with the path to your Tomcat home directory: Alias /struts-documentation $TOMCAT_HOME/webapps/struts-documentation Directory $TOMCAT_HOME/webapps/struts-documentation Options Indexes FollowSymLinks /Directory ApJServMount /struts-documentation/servlet /struts-documentation Location /struts-documentation/WEB-INF/ AllowOverride None deny from all /Location Alias /struts-example $TOMCAT_HOME/webapps/struts-example Directory $TOMCAT_HOME/webapps/struts-example Options Indexes FollowSymLinks /Directory ApJServMount /struts-example/servlet /struts-example Location /struts-example/WEB-INF/ AllowOverride None deny from all /Location 7* On all versions of Tomcat, the generated file above does not know anything about extension mappings defined in a web.xml file, so the *.do URIs that go to the controller servlet will not be recognized. To fix this, add the following line to the saved version of tomcat-apache.conf, after the corresponding line for the .jsp extension: AddHandler jserv-servlet .do 8* Ensure that the saved version of tomcat-apache.conf is referenced in your Apache httpd.conf configuration file. A typical use would have the following line at the bottom of httpd.conf: Include /usr/local/apache/conf/tomcat-apache.conf (I used: include d:/web/apache_1.3.19/Apache/conf/tomcat-apache.conf) 9* In order to recognize index.jsp as a default page for web applications, search in your httpd.conf for a DirectoryIndex directive. If you have one, add index.jsp to the end of the list, so that it might look like this: DirectoryIndex index.html index.jsp If you do not have such an entry, add one like this: DirectoryIndex index.jsp 10* Restart Apache to make it aware of the new applications. You should now be able to access the applications from a browser like this: http://localhost/struts-documentation http://localhost/struts-example --end pasted instructions---