tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Diedler <adied...@tecracer.de>
Subject AW: mod_jk Loadbalancer for 2 different tomcat Installations
Date Fri, 13 May 2011 05:27:14 GMT
Hello,
So in my worker.properties I would have a section for App1 with w1 and w2


# List the workers name
worker.list= loadbalancer,jkstatus,loadbalancer2
worker.maintain=60
# ----------------
# First worker
# ----------------
worker.worker1.port=8010
worker.worker1.host=server1
worker.worker1.type=ajp13
worker.worker1.lbfactor=75
worker.worker1.route=worker1
worker.worker1.activation=active

# ----------------
# second worker
# ----------------
worker.worker2.port=8010
worker.worker2.host=server2
worker.worker2.type=ajp13
worker.worker2.lbfactor=100
worker.worker2.route=worker2
worker.worker2.activation=active

# ----------------
# Third worker
# ----------------
worker.worker3.port=8012
worker.worker3.host=server1
worker.worker3.type=ajp13
worker.worker3.lbfactor=75
worker.worker3.route=worker3
worker.worker3.activation=active

# ----------------
# fourth worker
# ----------------
worker.worker4.port=8012
worker.worker4.host=server2
worker.worker4.type=ajp13
worker.worker4.lbfactor=75
worker.worker4.route=worker4
worker.worker4.activation=active



# ----------------------
# Load Balancer worker
# ----------------------
worker.loadbalancer.type=lb
worker.loadbalancer.balance_workers=worker1,worker2
worker.loadbalancer.sticky_session=true
worker.loadbalancer.sticky_session_force=false
worker.loadbalancer.method=Busyness
worker.loadbalancer.retries=3
worker.loadbalancer.secret=XXXX
# Define a 'jkstatus' worker using status
worker.jkstatus.type=status



And an additional section with w3 and w4 for the second cluster
# ----------------------
# Load Balancer worker new app
# ----------------------
worker.loadbalancer2.type=lb
worker.loadbalancer2.balance_workers= worker3,worker4
worker.loadbalancer2.sticky_session=true
worker.loadbalancer2.sticky_session_force=false
worker.loadbalancer2.method=Busyness
worker.loadbalancer2.retries=3
worker.loadbalancer2.secret=XXXX

Is this a good configuration? 

Greetings
Alexander Diedler



-----Urspr√ľngliche Nachricht-----
Von: Felix Schumacher [mailto:felix.schumacher@internetallee.de] 
Gesendet: Montag, 9. Mai 2011 13:29
An: Tomcat Users List
Betreff: Re: mod_jk Loadbalancer for 2 different tomcat Installations

Hello Alexander,
On Mon, 9 May 2011 11:48:54 +0200, Alexander Diedler wrote:
> Hello,
>
> I have a question about the configuration of loadbalancer with mod_jk 
> for Apache 2.2.
>
> We have 2 physical servers. Both have 2 different Tomcat 
> Installations. Tomcat 6.0.26 and 6.0.32. We make worker1 and worker2 
> for both servers Tomcat 6.0.26 (Serverport 8010) and define a 
> loadbalancer worker with member worker1 and worker2.
>
> Today we install the new application, that will be served by a 
> separate Tomcat (6.0.32) as a cluster. We define the worker 3 and
> worker4 for both servers Tomcat 6.0.32 (Serverport 8012) and add the 
> workers to the existing loadbalancing worker as members. Is this a 
> valid configuration or should we define a new loadbalancer worker 
> called loadbalancer2 for the worker3 and worker4?
Clusters of workers can be used only if all workers share the same apps.

If you have four workers (w1, w2, w3 and w4) and have two different sets of applications -
appset1 on w1 and w2; appset2 on w3 and w4 -, you must build two clusters and set the members
to w1 and w2 or w3 and w4 respectively.

Regards
  Felix
>
> Greetings
>
> Alexander Diedler


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


Mime
View raw message