Skip Headers
Oracle® Coherence Administrator's Guide
Release 3.7

Part Number E18679-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

5 Performing a Multicast Connectivity Test

Coherence includes a multicast test utility to help determine if multicast is enabled between two or more computers. The utility does not test load; each instance, by default, only transmit a single multicast packet every two seconds. For network load testing, see Chapter 4, "Performing a Network Performance Test."

The following sections are included in this chapter:

5.1 Running the Multicast Test Utility

The multicast test utility is run from the command line using either the com.tangosol.net.MulticastTest class or by running the multicast-test script that is provided in the COHERENCE_HOME/bin directory. A script is provided for both Windows and UNIX-based platforms.

The following example runs the utility using the MulticastTest class:

java com.tangosol.net.MulticastTest <command value> <command value> ...

The following example runs the utility using the script:

multicast-test <command value> <command value> ...

Table 5-1 describes the available command line options for the multicast test utility.

Table 5-1 Command Line Options for the Multicast Test Utility

Command Required/Optional Description Default

-local

Optional

The address of the NIC to transmit on, specified as an IP address

localhost

-group

Optional

The multicast address to use, specified as IP:port.

237.0.0.1:9000

-ttl

Optional

The time to live for multicast packets.

4

-delay

Optional

The delay between transmitting packets, specified in seconds.

2

-packetSize

Optional

The size of the packet to send. The default is based on the local MTU.

MTU

-display

Optional

The number of bytes to display from unexpected packets.

0

-translate

Optional

Listen to cluster multicast traffic and translate packets

none


5.2 How to Test Multicast

The example in this section demonstrates how to test if multicast address 237.0.0.1, port 9000 (the test's defaults) can send messages between two servers: Server A with IP address 195.0.0.1 and Server B with IP address 195.0.0.2.

Starting with Server A, determine if it has multicast address 237.0.0.1 port 9000 available for 195.0.0.1 by first checking the computer or interface by itself as follows:

From a command prompt, enter the following command:

multicast-test.sh -ttl 0

After pressing ENTER, the utility display how it is sending sequential multicast packets and receiving them. Example 5-1 illustrates sample output.

Example 5-1 Sequential Multicast Packets Sent by the Multicast Test Utility

Starting test on ip=servera/195.0.0.1, group=/237.0.0.1:9000,ttl=0
Configuring multicast socket...
Starting listener...
Tue Mar 17 15:59:51 EST 2008: Sent packet 1.
Tue Mar 17 15:59:51 EST 2008: Received test packet 1 from self.
Tue Mar 17 15:59:53 EST 2008: Sent packet 2.
Tue Mar 17 15:59:53 EST 2008: Received test packet 2 from self.
...

Press CTRL-C to stop further testing after several packets have been sent and received successfully.

If you do not see something similar to the above, then multicast is not working. Also, note that a TTL of 0 was specified to prevent the multicast packets from leaving Server A.

Repeat the same test on Server B to assure that it too has the multicast enabled for it's port combination.

Next, test multicast communications between Server A and Server B. For this test use a nonzero TTL which allows the packets to leave their respective servers. By default, the test uses a TTL of 4, if more network hops are required to route packets between Server A and Server B, specify a higher TTL value.

Start the test on Server A and Server B by entering the following command into each's respective command window and pressing ENTER:

multicast-test.sh

The following example demonstrates sample output for Server A:

Starting test on ip=servera/195.0.0.1, group=/237.0.0.1:9000, ttl=4
Configuring multicast socket...
Starting listener...
Tue Mar 17 16:11:03 EST 2008: Sent packet 1.
Tue Mar 17 16:11:03 EST 2008: Received test packet 1 from self.
Tue Mar 17 16:11:05 EST 2008: Sent packet 2.
Tue Mar 17 16:11:05 EST 2008: Received test packet 2 from self.
Tue Mar 17 16:11:07 EST 2008: Sent packet 3.
Tue Mar 17 16:11:07 EST 2008: Received test packet 3 from self.
Tue Mar 17 16:11:09 EST 2008: Sent packet 4.
Tue Mar 17 16:11:09 EST 2008: Received test packet 4 from self.
Tue Mar 17 16:11:10 EST 2008: Received test packet 1 from ip=serverb/195.0.0.2, group=/237.0.0.1:9000, ttl=4.
Tue Mar 17 16:11:11 EST 2008: Sent packet 5.
Tue Mar 17 16:11:11 EST 2008: Received test packet 5 from self.
Tue Mar 17 16:11:12 EST 2008: Received test packet 2 from ip=serverb/195.0.0.2, group=/237.0.0.1:9000, ttl=4.
Tue Mar 17 16:11:13 EST 2008: Sent packet 6.
Tue Mar 17 16:11:13 EST 2008: Received test packet 6 from self.
Tue Mar 17 16:11:14 EST 2008: Received test packet 3 from ip=serverb/195.0.0.2, group=/237.0.0.1:9000, ttl=4.
Tue Mar 17 16:11:15 EST 2008: Sent packet 7.
Tue Mar 17 16:11:15 EST 2008: Received test packet 7 from self.
...

The following example demonstrates sample output for Server B:

Starting test on ip=serverb/195.0.0.2, group=/237.0.0.1:9000, ttl=4
Configuring multicast socket...
Starting listener...
Tue Mar 17 16:11:10 EST 2008: Sent packet 1.
Tue Mar 17 16:11:10 EST 2008: Received test packet 1 from self.
Tue Mar 17 16:11:11 EST 2008: Received test packet 5 from ip=servera/195.0.0.1, group=/237.0.0.1:9000, ttl=4.
Tue Mar 17 16:11:12 EST 2008: Sent packet 2.
Tue Mar 17 16:11:12 EST 2008: Received test packet 2 from self.
Tue Mar 17 16:11:13 EST 2008: Received test packet 6 from ip=servera/195.0.0.1, group=/237.0.0.1:9000, ttl=4.
Tue Mar 17 16:11:14 EST 2008: Sent packet 3.
Tue Mar 17 16:11:14 EST 2008: Received test packet 3 from self.
Tue Mar 17 16:11:15 EST 2008: Received test packet 7 from ip=servera/195.0.0.1, group=/237.0.0.1:9000, ttl=4.
...

In the example both Server A and Server B are issuing multicast packets and seeing their own and each other's packets. This indicates that multicast is functioning properly between these servers using the default multicast address and port.

Note:

Server A sees only its own packets (1-4) until it receives packet 1 from Server B.

5.3 Troubleshooting Multicast Communications

Try the following if bidirectional multicast communication is not established:

If multicast is not functioning properly, consult with a network administrator or sysadmin to determine the cause and to correct the situation.