httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lataxes, Karl" <Karl.Lataxes...@nielsen.com>
Subject [users@httpd] Sticky Session Not Working With Apache 2.0.54 and Tomcat 7.0.8
Date Wed, 13 Jul 2011 13:09:54 GMT
We are attempting to run identical servlets under several Tomcat 7.0.8 nodes behind a load
balancer (Apache 2.0.54 using mod_jk), but we have been unable to get sticky sessions to work.
 Initial requests are forwarded to a node as expected, but subsequent requests from the same
client are being forwarded to the second node ala round robin, which triggers session not
found logic in our application and causes the connection to terminate.  Due to environment
limitations, we cannot employ session persistence to our Tomcat instances and must make use
of sticky sessions.  My Tomcat instances have been properly configured (HTTP connector commented
out, AJP 1.3 connected uncommented, jvmRoute attribute in each instance set to the workers
listed in workers.properties file).

Here are the mod_jk entries in my httpd.conf file:

LoadModule jk_module /<path_to>/apache/modules/mod_jk.so

JkWorkersFile /<path_to>/apache/conf/workers.properties
JkLogFile logs/mod_jk.log
JkLogLevel debug

JkMount /* loadbalancer

Here are the entries in my workers.property file:

worker.list=loadbalancer

worker.tomcat7A.type=ajp13
worker.tomcat7A.host=<host_name>
worker.tomcat7A.port=4911
worker.tomcat7A.lbfactor=1

worker.tomcat7C.type=ajp13
worker.tomcat7C.host=<host_name>
worker.tomcat7C.port=4931
worker.tomcat7C.lbfactor=1

worker.loadbalancer.type=lb
worker.loadbalancer.balance_workers=tomcat7A,tomcat7C
worker.loadbalancer.sticky_session=1

worker.jkstatus.type=status

What am I doing wrong?

Mime
View raw message