I will not talk about how to set up Apache + MySQL here. I just want to talk about how to install Tomcat:
========================================================== =
1. First, make sure that the relevant software is installed.
$ Sudo apt-Get install GCC Autoconf sun-j2sdk1.5
2. Download Tomcat
$ Http://apache.freelamp.com/tomcat/bin/apache-tomcat-5.5.12.tar.gz
3. Unzip Tomcat
$ Sudo tarzxvf jakarta-tomcat-5.5.12.tar.gz-C/OPT
$ Sudo mV/opt/jakarta-tomcat-5.5.12/opt/tomcat
4. Make sure there are in the/etc/environment file: (this step is not very sure whether it is required)
> Classpath =/usr/lib/j2sdk1.5-sun/lib
> Java_home =/usr/lib/j2sdk1.5-sun
5. start Tomcat
$ Sudo/opt/tomcat/bin/startup. Sh
If you can see the following prompt, it indicates that the startup is successful!
> Using catalina_base:/opt/tomcat
> Using catalina_home:/opt/tomcat
> Using catalina_tmpdir:/opt/tomcat/temp
> Using jre_home:/usr/lib/j2sdk1.5-sun
6. Test: Open Firefox and enter http: // localhost: 8080 in the address bar. If the default Tomcat interface is displayed, the test is successful!
7. Stop the Tomcat Service
$ Sudo/opt/tomcat/bin/shutdown. Sh
8. To obtain MySQL JDBC, enter the connector in the address bar of the Firefox browser.
9. Install JDBC
$ Tar-zxvf mysql-connector-java-3.1.10.tar.gz
$ Sudo CP mysql-connector-java-3.1.10/mysql-connector-java-3.1.10-bin *. Jar/usr/lib/j2sdk1.5-sun/lib