-
1. Re: problems of clustering server (picketlink, haproxy, failover)
rhusar Apr 10, 2012 7:12 AM (in response to alfred877)Hi Alfred,
the replication is not working because the cluster didn't form:
18:05:27,051 INFO [org.jboss.as.clustering.impl.CoreGroupCommunicationService.web] (MSC service thread 1-3) JBAS010206: Number of cluster members: 1
Since I dont see your full setup, I am not sure what the fix is, probably env (e.g. firewall) issues or missing <distributable/> tag?
And also you need to use sticky session instead of round-robin for performance and stability reasons:
I can't login. (the haproxy use "roundrobin" as it's load balance policy.)
HTH,
Rado
-
2. Re: problems of clustering server (picketlink, haproxy, failover)
alfred877 Apr 11, 2012 1:42 AM (in response to rhusar)Thanks for your reply, Rado.
The server log is from node 1 and I start up it before node 2. I could see
18:05:57,841 INFO [org.jboss.as.clustering.impl.CoreGroupCommunicationService.web] (MSC service thread 1-3) JBAS010206: Number of cluster members: 2
in the server.log from node 2. In the end of server.log which I attched, the log show
[org.infinispan.remoting.transport.jgroups.JGroupsTransport] (Incoming-1,null) ISPN000094: Received new cluster view: [2003vm32-1/web|1] [2003vm32-1/web, 2003vm32-2/web]
The 2003vm32-1 and 2003vm32-2 are the server hosts. I think the cluster is established. Am I right?
The firewall would not be the problem because I stopped it.
I've tried to depoly a simple application with " <distributable/>" tag in it's web.xml.
I can get the same session on both two server nodes and failover process works(I think).
After adding the JAAS to my application, I can't get the same result by the request. The JAAS seems change to a new session after logging in.
Maybe I should know how to cluster a secured application first. I don't really know how to do it.
Any tip or document I can reference?
I'm not from a English-speaking country and may not describe my problem clearly.
I've taken two weeks to clarify my problem but... Hope you can give me some suggestion, thanks a lot.
-
3. Re: problems of clustering server (picketlink, haproxy, failover)
alfred877 Apr 11, 2012 5:50 AM (in response to alfred877)After adding the JAAS to my application, I can't get the same result by the request. The JAAS seems change to a new session after logging in.
Let me modify my description. I changed my haproxy load balance policy to "source"(sticky session) and I logged in my application via JAAS.
Then I shutdown my server node 1 and expected that I should be able to continue accessing the secured resources by node 2. But I was redirected to login page.
My problem is similar to the post https://community.jboss.org/message/215607#215607 but the post is since 2009.
The first thing I want to clarify how I should do to failover secured application?