This Blog is intended to collect information of my various Intrests,pen my opinion on the information gathered and not intended to educate any one of the information posted,but are most welcome to share there view on them
Monday, August 2, 2010
Tomcat: Troubleshoot the Tomcat?
In order to run Tomcat, you will need to install JDK and set the JAVA_HOME environment variable to identify the location of the JDK environment on your system. I have chosen to use JDK 5.0.
2. Click on Download JDK 5.0 Update 6 to go to the download page.
3. Click Accept to accept the license agreement.
4. Next choose the Linux self-extracting file. This is the download for the self-extracting binary file rather than the rpm.
5. Download to your preferred download directory. Change to that directory and make it executable by executing the following command:
chmod +x jdk-1_5_0_06-linux-i586.bin
6. Now execute the file:
7. You should now have a new directory called j2sdk1.5-sun. Now move this directory to the location where it should be run. I chose /usr/lib/.
mv j2sdk1.5-sun /usr/lib
8. Now create a symbolic link called jdk to JAVA_HOME by the following command. This allows you to easily switch back and forth between different jvms should you ever need to
ln -s j2sdk1.5-sun jdk
8. Now we need to set the JAVA_HOME environment variable. Add the following at the end of /etc/profile just after export PATH.
/etc/profile is executed at startup and when a user logs into the system. In order to update the environment you will need to log out and log back in to the system.
10. Check to make sure JAVA_HOME is defined correctly by executing the command below. This should report the location of the Java SDK which should be /usr/lib/jdk.
11. Now test Java with the following command. You should be returned with /usr/bin/java. If so, you have successfully completed this section.
Download the binary version to your preferred download directory from here: http://tomcat.apache.org/download-55.cgi. Choose the tar.gz from the core section for 5.5.15.
Now change to that directory and extract the files using the following command:
cd /mydownloads (be sure to change to your download directory)
tar xvzf apache-tomcat-5.5.15.tar.gz
You should now have a new directory called apache-tomcat-5.5.15. Now move this directory to the location where it should be installed. Again, I chose /usr/lib/. Note that this location will be referred to as CATALINA_HOME in the Tomcat documentation.
mv apache-tomcat-5.5.15 /usr/lib
Next change to the /usr/lib/ directory.
Now create a symbolic link called apache-tomcat to CATALINA_HOME by the following command.