Enable load balancing in the application servers – Apple Mac OS X Server v10.3 User Manual
Page 51

worker.JBoss2.port=9007
18. Change line 27 so that it references the second node. It should look similar to this:
worker.JBoss2.host=node2.mydomain.com
19. Change line 31 to:
worker.JBoss2.cachesize=10
20. Add the following line to the file to enable sticky sessions:
worker.loadbalancer.sticky_session=1
21. Save the file.
Enable Load Balancing in the Application Servers
For load balancing to work, each application server has to report its existence to the web server. Follow
these steps to configure the application-server so that they identify themselves to the web server:
1.
Open the
jboss-service.xml
file, located at
/Library/JBoss/3.2/deploy-cluster/deploy/jbossweb-tomcat41.sar/META-INF
, in a text
editor.
For non-cluster deployment, open the
jboss-service.xml
file at
/Library/JBoss/3.2/deploy-standalone/deploy/jbossweb-tomcat41.sar/META-INF
.
2.
Look for the following line:
3.
Edit the line so that it looks like this:
4.
Look for the following lines:
5.
Remove the
!--
at the beginning of the first line and the
--
and end of the last line while making
sure to leave the left angle bracket and the right angle bracket in place.
6.
Save the file.
7.
Repeat steps 1 through 6 for the second application server, but set
jvmRoute
to
"JBoss2"
in step
3.
Load Balancing and Clustering
51
2005-08-11 | © 2003, 2005 Apple Computer, Inc. All Rights Reserved.
C H A P T E R 5
Balancing User Load and Replicating Sessions