Tomcat Installation

Installing Tomcat on VPS

Tomcat Web Hosting » Installation of Tomcat server on VPS

TomcatJSPZone offers three Tomcat server choices: Tomcat 4, Tomcat 5, Tomcat 6 and latest Tomcat 7.

Main difference between the three servers are JDK support, Servlet & JSP version.

Tomcat 4 Tomcat 5 Tomcat 6 Tomcat 7
JSP v 1.2 JSP v 2.0 JSP v 2.1 JSP v ?
Servlet v 2.3 Servlet v 2.4 Servlet v 2.5 Servlet v ?
JDK 1.4 JDK 5 JDK 6 JDK ?

With JSPZone`s VPS (Virtual Private Server) tomcat installation is easy. Installation process is done with command 'yum' on shell prompt.

To list all available Tomcat rpm packages log into vps server via SSH and type: yum list | grep -i tomcat

[root@vps /]# yum list | grep -i tomcat
eroute-tomcat4.i386    4.1.37-1    eroute
eroute-tomcat5.i386    5.5.26-1    eroute
eroute-tomcat6.i386    6.0.18-1    eroute

Now lets install Tomcat 5 - version 5.5.26 - we type: yum -y install eroute-tomcat5

[root@vps /]# yum -y install eroute-tomcat5
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Excluding Packages in global exclude list
Finished
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package eroute-tomcat5.i386 0:5.5.26-1 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

===============================================================================
Package Arch Version Repository Size
===============================================================================
Installing:
eroute-tomcat5 i386 5.5.26-1 eroute 9.6 M

Transaction Summary
===============================================================================
Install 1 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 9.6 M
Downloading Packages:
eroute-tomcat5-5.5.26-1.i386.rpm | 9.6 MB 00:01
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : eroute-tomcat5-5.5.26-1.i386 1/1

Installed:
eroute-tomcat5.i386 0:5.5.26-1

Complete!

Tomcat installation process took us six seconds. Now your tomcat server is ready & installed in /var/tomcat5/ folder

[root@vps /]# ls /var/tomcat5/
bin common conf logs server shared temp webapps work

[root@vps /]# ls /var/tomcat5/conf
Catalina catalina.properties logging.properties
server-minimal.xml tomcat-users.xml catalina.policy
context.xml server-default.xml server.xml web.xml

[root@vps /]# ls /var/tomcat5/bin/
bootstrap.jar commons-logging-api-1.1.1.jar jmxaccessor-tasks.xml shutdown.bat
tomcat-native.tar.gz version.bat catalina-tasks.xml cpappend.bat jsvc.tar.gz
shutdown.sh tomcat5.exe version.sh catalina.bat digest.bat service.bat startup.bat
tomcat5w.exe catalina.sh digest.sh setclasspath.bat startup.sh tool-wrapper.bat
commons-daemon.jar jkstatus-tasks.xml setclasspath.sh tomcat-juli.jar
tool-wrapper.sh

[root@vps /]# ls /var/tomcat5/webapps/
ROOT balancer jsp-examples servlets-examples tomcat-docs webdav
[root@blog /]#

Now start tomcat server by typing: service tomcat5 start

[root@vps /]# service tomcat5 start
Starting tomcat server...

To verify that your tomcat server is running, type: ps aux | grep java

[root@blog /]# ps aux | grep java
root 3703 22.6 1.8 190480 38836 ttyp1 Sl 21:13 0:04 /usr/java/jdk1.6.0/bin/java -server -Xms32m -Xmx32m
-Djava.awt.headless=true -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
-Djava.util.logging.config.file=/var/tomcat5/conf/logging.properties
-Djava.endorsed.dirs=/var/tomcat5/common/endorsed
-classpath :/var/tomcat5/bin/bootstrap.jar:/var/tomcat5/bin/commons-logging-api.jar
-Dcatalina.base=/var/tomcat5 -Dcatalina.home=/var/tomcat5
-Djava.io.tmpdir=/var/tomcat5/temp org.apache.catalina.startup.Bootstrap start

Now open your browser and go to: http://youripaddress:8080/ and you should see Tomcat welcome screen as shown below:

Tomcat installation

With JSP Zone's tomcat hosting service everything is ready within seconds and you can start deploying your java application.
You can upload war files through SFTP or via Tomcat Manager which is already configured. You username & password are located in /var/tomcat5/conf/tomcat-users.xml. It's highly recommended to change default password.

If you decide to try Tomcat 6 or Tomcat 4 and you want to remove Tomcat 5 (current installation), you need to type:

[root@blog ~]# service tomcat5 stop
Stopping tomcat server...
[root@blog ~]# rpm -e eroute-tomcat5
Stopping tomcat server...
Contact Us Help Desk FAQ Help Desk Dedicated Servers Hosting Services Servers & Network Support Testimonials Order Now About JSPZone Home