users@glassfish.java.net

Re: High Availability Session Persistence does not work.

From: <glassfish_at_javadesktop.org>
Date: Mon, 22 Oct 2007 00:55:52 PDT

Hi lwhite,

 Yes you read that correctly as "..SessionData is replicated when everything is done ON one host "
  *sorry for typing errors.*

and thanks for the correction about shared memory settings (im clutching at straws, so its good to know thats not the problem).

 Im not using the Alteon lb. Im actually using the heartbeat and ldirector packages from Debian (via apt-get install)

 But I don't think the ldirector is at fault either (it should be pretty standard).
 I have a seperate DAS on one machine(m1)
 I created 3 instance on second machine/NodeAgent(m2) and three on the other third machine(m3).

 If I do the 'port-hoping' on the second machine & hop between instances
 http://m2:38080/clusterjsp/ &
 http://m2:38081/clusterjsp/ &
 http://m2:38082/clusterjsp/

 I see the Session data replicated. *All good!*

 I then add these three ports to my load balancer in the ldirector.cf file
 (loadbalancer address is 192.168.11.105)
  virtual=192.168.11.105:38080
   real=m2:38080
   real=m3:38080
  ...and so on for each instance.

Now I stop machine m3 so I only ever go to m2 (via loadbalancer)
then I can use the loadbalancer address:instance-port
  http://192.168.11.105:38080/clusterjsp/ & 'port-hop' between instances.
  http://192.168.11.105:38081/clusterjsp/ &
  http://192.168.11.105:38082/clusterjsp/ &

 and I still see the data replicated between instances.

 now If I turn on machine m3.

 I wait until the Server changes till I see Im on (third machine)m3.
 I repeat the above.

 While I continue to end up on an instance on m3 replication works.(between instances)
 As soon as I get directed back to machine m2 the session is reset.

(1)
 say I use the the DAS and stop all instances on m3.
 then I get redirected to m2 and Session Resets.

(2)
 I remove the file ldirector checks to see if the node is up(forcing ldirector to use other node)
 Session resets.
[Message sent by forum member 'sean_au' (sean_au)]

http://forums.java.net/jive/thread.jspa?messageID=241453