This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
I am looking at installing Tomcat for our students here at the Community College to teach JSP and Servlets. I have run into the problem of configuring Tomcat on our Win 2000/XP machines. Due to security, students cannot change any of the enviroment variables or autoexec.bat files directly. We use Java 1.4.2 and have tomcat 5.0.19 installed hard drive. Some Questions: 1. First how can we let the students use tomcat and configuring tomcat usin the DOS command line? (I.E what commands to use, to set Java Home, changing port number, etc.)
2. Were are good tutorials on setting Tomcat via command line as a standalone machine? I have done seaches on this most books/website but can only find a few real good simple tutorials on this. 3. Finally and good recommendations on Tomcat Reference books. Thanks JC
Tomcat is not really designed to be configured from the command line - there are just too many parameters. See server.xml for example. You can set Environment variables that just apply to one Command Prompt window - they don't have to be global. You can see this being done in the startup.bat and catalina.bat files. Is the goal to have one running Tomcat instance per student, or would one "web application" per student be enough? Bill
Joined: Oct 06, 2002
I believe one the second option would suffice. Here is something I found that I tried to get to work: set JAVA HOME=c:\j2sdk1.4.0_02 C:\jakarta-tomcat-5.0.19\bin>startup Change port number: C:\jakarta-tomcat-5.0.19\conf\server.xml Does this look right?
Originally posted by James Chegwidden: I have run into the problem of configuring Tomcat on our Win 2000/XP machines. Due to security, students cannot change any of the enviroment variables or autoexec.bat files directly. JC
I would suspect that your students would run into the same type of security issues even if editing the files from the command line, else you have to question the security mesures. Anyway, you can use the DOS edit program (c:> edit) to edit the text files. The program has a very nice and easy DOS menu interface.
SCJP, SCWCD, SCBCD, IBM CSD WebSphere v5, <br />A+, MCP 2000 and 2000 server, CST, and few incompleted certification tracks.<br /> <br />Ivory Coast<br /> <br />Analyze your web Request/Response @ <a href="http://webtools.servehttp.com" target="_blank" rel="nofollow">http://webtools.servehttp.com</a> down for a while...
Author and all-around good cowpoke
Joined: Mar 22, 2000
A google search for "teaching servlets with tomcat" turned up lots of possibly useful references.
Joined: Oct 06, 2002
Thanks for all of your help. I figured it out and works just fine. I did this weeks ago but forgot to tell all of you.
I now have created a step by step handout for my students to use.