CopyDisable

Monday, 15 August 2011

Creating new Tomcat instance - 2nd Way

In one of my previous posts Creating a new Tomcat5.5 Instance , I wrote how to create multiple tomcat instances using one utility called tomcat service manager. When I was migrating applications from one server to the new server, I had to create multiple Tomcat services. But the problem I faced was that the new server was Windows 2003 64 bit version and Tomcat Service Manager utility was not running in it. So I had to look for some other option to create the new Tomcat instances and services. So I did the following steps to create the new instances
1) I had downloaded the zip version of Tomcat (Do not download the windows installer version).
2) Extract it to the desired location. Suppose I want tomcat in D:\TomcatOER for deploying my OER confluence application.
3) Edit the server.xml file and change default shutdown port, default http port, default connection port, redirect port of the tomcat instance.
4) Now we have to create the windows service for this instance.
Tomcat zipped version comes with service.bat batch file to create the windows service.
Now we are going to run a small batch script which first sets the environment variables and then call the service.bat file to create the service named TomcatOER.
REM ###This is the path of the installed JDK
set JAVA_HOME=C:\Program Files\Java\jdk1.6.0_20

REM ###Path where I unzipped Tomcat

set TOMCAT_HOME=D:\TomcatOER
set CATALINA_BASE=D:\TomcatOER
D:
cd %TOMCAT_HOME%\bin
call service.bat install TomcatOER
Run this script to create the Tomcat service named TomcatOER.
5) Now we can use Tomcat6w GUI application for monitoring and configuring Tomcat service.
Run this from command line to configuring the TomcatOER service.
tomcat6w //ES//TomcatOER


জয় আই অসম,
প্রণব শর্মা

1 comment:

Adit said...

Whether you are aware of voip texting USA or not, this is one of the most powerful approaches of reaching to your clients and to send them all of the news and all the good things of your business offers to them.

Post a Comment