Question

I am trying to create a standalone cluster in Wildfly 8.
I am referring to http://middlewaremagic.com/jboss/?p=1952.
I was successful in creating the cluster on same machine, but can't create the same on different machines. I started the server on both machines as follows:

1) On machine 1 > Go to cmd > jboss-wildfly\bin > run following command:

standalone.bat -c standalone-ha.xml -b 10.10.54.27 -u 230.0.0.4 -Djboss.server.base.dir=../standalone -Djboss.node.name=nodeOne
(10.10.54.27 is IP of machine 1)

1) On machine 2 > Go to cmd > jboss-wildfly\bin > run following command:

standalone.bat -c standalone-ha.xml -b 10.10.52.42 -u 230.0.0.4 -Djboss.server.base.dir=../standalone -Djboss.node.name=nodeTwo
(10.10.52.42 is IP of machine 2)

The servers are getting started without any problem, but the nodes can't see each other. I used ClusterWebApp.war (downloaded from same site given above) for testing the cluster.

Am I missing something? Please help.

Was it helpful?

Solution 2

I got the problem. For this kinda clustering to work, multicast protocol needed to be supported on network switches and routers.

Previously I tried doing it on my laptop for which multicast protocol is enabled. So, I successfully created cluster on same machine (i.e. my laptop). However, other machine is one of the servers in my network, for which multicast was not enabled. Hence it was failing when tried on two different machines.

Very basic problem!! After correcting this, cluster is working fine.

OTHER TIPS

Most likely UDP broadcasting/multicasting is not allowed on your network (as of today, this would be the case on AWS VPCs for instance)

There is a test you can run to confirm this: http://www.techstacks.com/howto/troubleshoot-jgroups-and-multicast-ip-issues.html

If this is the case, you may have to cluster using tcp. These links explain how this can be done http://middlewaremagic.com/jboss/?p=2015 http://www.redhat.com/summit/2011/presentations/jbossworld/whats_new/wednesday/ban_w_310_running_in_the_cloud.pdf

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top