Jgroups Multicast Tester Utility

  • KM00693628
  • 23-Dec-2013
  • 30-Sep-2015

Summary

This document introduces how to use Jgroups Multicast Tester Utility.

Question

How to use Jgroups Multicast Tester Utility?

Answer

To test multicast ability, you can use the built-in utility provided by Jgroups. This is not a SM specific tool--it is 3rd party to HP. Usually, you would use this tool BEFORE you install and implement SM in an environment to make sure that the SMs's multicast requirement is met. In some cases, you can use this tool to troubleshoot incidents where all of a sudden the HP SM loadbalancer or servlets cannot properly communicate with each other during startup.

To begin: Make sure to STOP ALL running SM instances.

From a cmd window, “cd” into the RUN\lib directory; e.g.

cd "C:\Program Files\HP\Service Manager 9.20\Server\RUN\lib"

Then run the Jgroups McastReceiverTest program:

java -Djava.net.preferIPv4Stack=true -cp "<PATH TO RUN/lib/jgroups<version>.jar>" org.jgroups.tests.McastReceiverTest -bind_addr <groupbindaddress parm in sm.ini> -mcast_addr <groupmcastaddress in sm.ini> -port <groupport parm in sm.ini>

– default mcast_addr is typically  228.xx.xx.10 or according to your log output, it is being set to 228.x.xx.45. Default groupport is typically 45588, e.g.

C:\> java -Djava.net.preferIPv4Stack=true -cp "C:\Program Files\HP\Service Manager 9.20\Server\RUN\lib\jgroups-all-2.6.15.jar" org.jgroups.tests.McastReceiverTest -bind_addr 192.xx.x.114 -mcast_addr 228.x.xx.45 -port 45588

When it runs successfully, you should see something like below (leave it up and running) :

Socket=0.0.0.0/0.0.0.0:45588, bind interface=/192.xxx.xx.114

Open another cmd window and run the Jgroups McastSenderTest program:

java -cp "C:\Program Files\HP\Service Manager 9.20\Server\RUN\lib\jgroups-all-2.6.15.jar" org.jgroups.tests.McastSenderTest -bind_addr <groupbindaddress parm in sm.ini> -mcast_addr <groupmcastaddress in sm.ini> -port <groupport parm in sm.ini> -ttl 32

Default mcast_addr is typically   228.xx.xx.10 or according to your log output, it is being set to  228.x.xx.45. Default groupport is typically 45588, e.g.

C:\>java -Djava.net.preferIPv4Stack=true -cp "C:\Program Files\HP\Service Manager 9.20\Server\RUN\lib\jgroups-all-2.6.15.jar" org.jgroups.tests.McastSenderTest -bind_addr 192.xxx.x.114 -mcast_addr 228.x.xx.45 -port 45588 -ttl 32

Running this command, should allow you to type in the window. Anything you type in the McastSender’s window should appear in the McastReceiver window.  If this doesn’t work (what you type doesn’t appear in the Receiver window) then there is an issue with multicast config; bad IP, bad network, bad port; try using other values. Get the customer's network engineers on the line and have them explain why multicast is not confiugred correctly--you can provide them the output from this test so they understand the parameters of the test and its results.