load balancer - requests repeated several times
nmounasamy Jun 28, 2004 12:13 AMHi!
There seems to be a weird issue with modjk2 in its load balancing behavior. I have Apache 2049 load balancing over two jboss instances (stickySession=1).
At times, when a request is made to a guarded page (PAGE 1) (which requires login via another page - PAGE 2 if user has not already logged in), the request is repeated several times with status code (302). And finally the page times out.
This issue is noticed only when the guarded page is accessed via a domain (*.nanda1.com in the example below) that is associated with a load balancer (lb).
The same page when accessed via a domain (*.nanda.com) that is associated with a single worker works fine.
Does anyone know what the issue is with the config, or if there is a known bug with the modjk/jboss, and in that case, if there is a work around?
I am using Apache 2.0.49 and Jboss 3.2.3.
Here are the settings i have in httpd.conf and workers2.properties.
httpd.conf
==========
# *.nanda.com
<VirtualHost *>
ServerName nanda
ServerAlias *.nanda.com
<LocationMatch "/*">
JkUriSet worker ajp13:10.1.1.45:10103
</ LocationMatch>
< /VirtualHost>
# *.nanda1.com
<VirtualHost *>
ServerName main
ServerAlias *
<LocationMatch "/*">
JkUriSet group lb
< /LocationMatch>
< /VirtualHost>
workers2.properties
===================
[lb:lb]
stickySession=1
# STEP 2: Channel ....
[channel.socket:10.1.1.45:10103]
group=lb
tomcatId=nanda
[channel.socket:10.1.1.45:10403]
group=lb
tomcatId=dev
# STEP 3: AJP3 ....
[ajp13:10.1.1.45:10103]
channel=channel.socket:10.1.1.45:10103
group=lb
tomcatId=nanda
[ajp13:10.1.1.45:10403]
channel=channel.socket:10.1.1.45:10403
group=lb
tomcatId=dev
[uri:nanda:/*]
worker=ajp:10.1.1.45:10103
[uri:main:/*]
group=lb
workers2.properties
===================
When requests are repeated, Apache's error.log logs the following several times.
Requests are forwarded repeatedly to both the jboss instances that are associated
with the load balancer - lb.
Apache Log
==========
[Sun Jun 27 23:38:20 2004] [notice] channelApr.receive(): Received len=2 type=5
[Sun Jun 27 23:38:20 2004] [notice] channelApr.receive(): Received len=598 type=4
[Sun Jun 27 23:38:20 2004] [notice] channelApr.receive(): Received len=2 type=5
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=325 type=4
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=2 type=5
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=598 type=4
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=2 type=5
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=325 type=4
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=2 type=5
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=598 type=4
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=2 type=5
[Sun Jun 27 23:38:21 2004] [notice] channelApr.receive(): Received len=325 type=4
I would appreciate your help!