Currently, Tomcat is the most popular Jsp environment. Tomcat5.0 contains a Web server. If it is a test, you do not need to integrate Tomcat with IIS or Apache. You can perform Jsp testing on the Web server that comes with Tomcat.
Install JDK before installing Tomcat 2003 (if it is Windows server 2003, JDK must be installed, because Windows server 2003 does not contain JVM-Windows server is released when the MS and SUN is just awkward ). After installation, you need to set several environment variables:
JAVA_HOME = E: j2sdk1.4.2 _ 04
CLASSPATH = E: j2sdk1.4.2 _ 04lib; E: j2sdk1.4.2 _ 04libools. jar
Add.; E: j2sdk1.4.2 _ 04in in Path;
CATALINA_HOME = E: Tomcat 5.0
TOMCAT_HOME = E: Tomcat 5.0
My JDK version is 1.4.2 and is installed in the E: j2sdk1.4.2 _ 04 folder.
The environment variables JAVA_HOME and CATALINA_HOME must be added (at least for reference ). CLASSPATH also says that it will be added, but it does not seem to have any impact if I didn't add it. Add ".; e: j2sdk1.4.2 _ 04in; "the same is true. I can run it without jsp, but it is compiled manually in the DOS window. java class. the class file is affected because the javac.exe compilation command file cannot be found. As for the dot "." In the path, I used to need it in resin. I haven't confirmed whether it is necessary in Tomcat.
We also found that the values of CATALINA_HOME and TOMCAT_HOME are the same. I estimate that TOMCAT_HOME is used in earlier versions of Tomcat, and CATALINA_HOME is used now. However, these two items do not seem to be incompatible. If they are added or any of them is added, Jsp will not be affected. However, I suggest using a CATALINA_HOME.
Tomcat5.0 is easier to set the virtual path, because it can be managed in the Web environment. Http: // [url]: 8080/admin can enter the Management Interface (the Administrator admin password can be set during Tomcat installation), in Tomcat Server-Service (Catalina) -Context can be added under the Host (localhost), similar to IIS
In the virtual Path: Document Base refers to the file Path starting from the actual E: Tomcat 5.0 websiteroot, and Path refers to the virtual Path name starting from the virtual, for example, "/mytest ". Tomcat seems to be a little poorly designed here. You only need to add a new Context, save it, click the "Commit Changes" button, and then click Context to view it. The interface will return to the logon interface, however, sometimes an error occurs on the page. You must manually enter http: // [url]: 8080/admin again. After Context is added, the Apache Tomcat service must be "disabled/started" (in the Windows console ). It is said that in the http: // localhost: 8088/manager Management Interface, Start and Stop can be used to restart the corresponding Context, but after I Stop, Start cannot be started. Click Undeploy to delete the Context. Note: The physical folder corresponding to the Context is also deleted !! That is to say, you have made an application and moved it here. If you are not careful, you will delete it-it is worse than the virus. Be careful !!