Concerning the load balancer worker: you need to set jvmRoute in
server.xml on your Tomcat servers. The value of the respective jvmRoute
has to be wrkr1 and wrkr2.
This will add that string to the session id (JSESSSIONID cookie or
jsessionid= URL part) and mod_jk strips it from there to learn, where
the sticky request should go to.
Regards,
Rainer
Tim Alberts wrote:
Well I found one problem with my workers.properties, but it didn't fix
my problem. I used the deprecated 'balanced_workers' on my load
balancer configuration instead of the balance_workers. So I'm still
stuck, any suggestions?
Tim Alberts wrote:
I have two tomcat servers (5.5.23) and running mod_jk (1.2.20) with
load balancing behind apache. I have a web application that needs to
maintain session information. What I'm seeing is that the load
balance is alternating requests between the servers equally, as
expected, but sessions are getting lost when going between the
servers. I thought from reading that the default is
sticky_session=True which means the mod_jk will keep sessions going to
the same server (if it is available..). This is obviously not
happening. Am I doing something wrong, or is there a problem?
# workers.properties - ajp13
#
# List workers
worker.list=lb,jkstatus
#
# Define wrkr1
worker.wrkr1.port=8009
worker.wrkr1.host=msi1
worker.wrkr1.type=ajp13
worker.wrkr1.socket_timeout=300
worker.wrkr1.lbfactor=1
#
# Define wrkr2
worker.wrkr2.port=8009
worker.wrkr2.host=msi2
worker.wrkr2.type=ajp13
worker.wrkr2.socket_timeout=300
worker.wrkr2.lbfactor=1
#
# Define lb
worker.lb.type=lb
worker.lb.sticky_session=True
worker.lb.sticky_session_force=False
worker.lb.balanced_workers=wrkr1,wrkr2
#
# Define a 'jkstatus' worker using status
worker.jkstatus.type=status
Second, I see a reference to a Session Manager in the Tomcat
documentation that can maintain session data across multiple servers.
This is the first I've heard about this, is this something Tomcat has
built in that I need to enable, or is this third party or something I
need to write on my own? (I will be reading more, but quick info from
users is helpful).
Thank you for any help.
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]