JBoss5 Clustering – Testing multicast capabilities

JBoss5 Clustering uses the JGroups component for efficient formation of its clusters and efficient communication between its cluster members.  JGroups in turn uses IP Multicast.

To test whether multicast IP is working properly you can use two small test programs provided in the JGroups package (org.jgroups.tests): McastReceiverTest and McastSenderTest found in <jboss_home>/server/all/lib.

To test whether multicast is setup correctly, start the receiver:

java -cp jgroups.jar org.jgroups.tests.McastReceiverTest -mcast_addr 230.0.0.4 -port 10520

and then start the sender:

java -cp jgroups.jar org.jgroups.tests.McastSenderTest -mcast_addr 230.0.0.4 -port 10520

If that doesn’t work, you should first establish whether multicast networking is properly enabled for your host.  This can be done via the following network-level tests.  Start tcpdump to listen for traffic:

$ sudo tcpdump -ni en1 host 230.0.0.4

where ‘en1′ is the name of a network interface (see ifconfig -a or ipconfig -a for a list of network interfaces for your host). Then send out some pings on the multicast address:

$ ping -t 1 -c 2 230.0.0.4

In all of these examples I’m using the multicast address of 230.0.0.4.  Yours maybe different but should be in the range: 224.0.0.0 – 239.255.255.255


You can follow any responses to this entry through the RSS 2.0 feed. Both comments and pings are currently closed.

AddThis Social Bookmark Button

Comments are closed.