tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier ...@ice-sa.com>
Subject Re: Multiple tomcat Instances on Same Server and One Apache Instance
Date Mon, 14 May 2012 08:37:07 GMT
Pid * wrote:
> On 13 May 2012, at 20:33, "André Warnier" <aw@ice-sa.com> wrote:
> 
>> Pid wrote:
>>> On 11/05/2012 18:53, Vickie Troy-McKoy wrote:
>>>> Hi, I am in need of a little help.
>>>> I have 2 tomcat instances running on the same machine and one apache instance
running on a different machine.  I configured jk_mod to access the 1st tomcat instance.  Now,
I have a second tomcat instance running on the same server as the 1st instance.  I would like
to access both tomcat instances via the one apache webserver instance.  Because some requests
are referenced by the same name, there is a conflict.
>>>> On the tomcat server in server.xml, one instance is running on port 8009
and the 2nd instance (in another directory structure) is running on 7009.
>>>>
>>>> On the apache server in httpd.conf, I have the following:
>>>>
>>>> Listen 80
>>>> .
>>>> .
>>>> .
>>>> LoadModule jk_module modules/mod_jk.so
>>>>
>>>> #
>>>> JkWorkersFile conf/workers.properties
>>>> JkMount /abc* instance1
>>>> JkMount /xyz* instance2
>>>>
>>>> In workers.properties, I have the following:
>>>>
>>>> worker.list=instance1, instance2
>>>> #
>>>> worker.instance1.port=8009
>>>> worker.instance1.host=server.xxxx.com
>>>> worker.instance1.type=ajp13
>>>> worker.instance1.lbfactor=1
>>>> worker.instance1.socket_keepalive=1
>>>> #
>>>> worker.instance2.port=7009
>>>> worker.instance2.host=server.xxxx.com
>>>> worker.instance2.type=ajp13
>>>> worker.instance2.lbfactor=1
>>>> worker.instance2.socket_keepalive=1
>>>>
>>>> When I call abc*, it goes to instance1; and when I call xyz*, it goes to
instance2.  However, both instances have apps that start with "tsa".  How do I configure the
apache webserver to service the "tsa" app for both tomcat instances?
>>> configure a load balancer (worker) that uses the (other) two workers, in addition
to the
>>> two workers, and add it to the worker list.
>> I think that rather than be added to the workers list, the load-balancer worker must
be the only one in the list.  You then tell the balancer to balance the two other workers.
> 
> Then the two individual apps won't work, as they're not present on both servers.

Oh. I did not read the OP's requirements carefully enough.  Apologies, your instructions 
were correct for the OP.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message