December 23rd, 2002, 03:15 AM
Help setting up Tomcat 4 w/ Apache 2
Well i got it setup, and it runs, BUT
it wont compile anything. I get an exception thrown saying unable to compile and a classname.
I looked at the tomcat window and it says can not find
JAVA_HOME might not point to the JDK, but
JAVA_HOME is set to
where my jdk.
i even tried setting JAVA_HOME to c:\j2sdk1.4.1_01\bin
Any ideas on this?
EDIT: Ok Servlets are working fine. Well those that came with the examples are working (were they precompiled??)
But no JSP pages work.
Here is the exact error i get
type Exception report
description The server encountered an internal error () that prevented it from fulfilling this request.
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
Last edited by Shocka; December 23rd, 2002 at 03:26 AM.
December 23rd, 2002, 04:57 AM
I could swear I've run into this before, but specifics are escaping me right now.
How is your classpath set? I think you need the tools.jar file in there in order to compile stuff.
Also, I seem to remember the Tomcat 4.1 install figuring all that stuff out for itself... Maybe I was just lucky.
December 30th, 2002, 12:50 PM
I have JAVA_HOME set I have CATALINA_HOME set
CATALINA_HOME c:\Program Files\Apache Group\Tomcat 4
i cant figure out whats wrong?
reading the error from the Tomcat server screen it says basically can not find tools.javac.Main in classpath but its set..
Oh well ill keep trucking.
December 30th, 2002, 01:04 PM
OK NOW i am even more confused I just decided to run tomcat
by using catalina.bat run
and IT WORKS!!!!
but their start tomcat link it created doesnt work.. Now im confused and the next step is to figure out how to start tomcat so the command window isnt there.
December 30th, 2002, 03:58 PM
The only way to get rid of the command window (as far as I know) is to run it as a service.
December 30th, 2002, 04:21 PM
yah i gotta figure out how to get this to work. I have it as a service but it starts and stops. No idea why..
December 30th, 2002, 06:27 PM
Well, I just did a fresh install with jdk 1.4.0 and Tomcat 4.1.
I don't have any environment variables set, and I have the jdk installed on my D: drive.
The setup found the jdk, asked me what I wanted to install (nt service, etc.), and where I wanted to install it (D:, again). It installed, started the service, and now http://localhost:8080/index.jsp has some info about jakarta apache tomcat etc.
So, my recommendation to you (since this has been taking forever ), is to uninstall tomcat, java, etc. Install the 1.4.x jdk. Grab the latest windows binary for tomcat at http://mirrors.theonlinerecordstore....cat-4.1.18.exe and install. It should go seemlessly .
January 1st, 2003, 01:03 AM
advice taken will do after i get back from india in 3 weeks
January 1st, 2003, 01:46 AM
Ahhhh, man. But that's, like, practically forever!
Let me know how it goes.
March 26th, 2003, 09:47 PM
I ran into exactly the same problem
My conclusions are that, the default installation of the Service done by the installer is incorrect, there must be a missing parameter.
What I did is that, I stopped the Service, wich was displayed as Apache Tomcat 4.1 on my win2k Pro machine
then, I ran the startup.bat file, and everything ran just fine, so I tought maybe the service was not installed correctly
well, Then, I ran the shutdown.bat file, and started the Service, everything ran fine, except for the Add User Database option in the Administration web interface for tomcat, so I suppossed some parameter was not working
what I did is that I run the uninstall method of the tomcat.exe to delete the apache tomcat 4.1 service, as this with the command line, I was located at the bin directory of the tomcat installation
Then I typed manually, well, I did not really type it, I did a copy paste from a URL I found through a google search at https://instruct.unc.edu/wcb/schools...ssages/11.html
tomcat.exe -uninstall "Apache Tomcat 4.1"
The trick is that everything has to be in one line, (with quotes and everything, as it is here bellow)
The new service is now named Tomcat, and everything runs just fine.
"%CATALINA_HOME%\bin\tomcat.exe" -install Tomcat "%JAVA_HOME%\jre\bin\client\jvm.dll" -Djava.class.path="%CATALINA_HOME%\bin\bootstrap.jar;%JAVA_HOME%\lib\tools.jar" -Dcatalina.home="%CATALINA_HOME%" -Xrs -start org.apache.catalina.startup.Bootstrap -params start -stop org.apache.catalina.startup.Bootstrap -params stop -out "%CATALINA_HOME%"\logs\stderr.log
I am happy at last !!!!