users@shoal.java.net

Re: What does the "same subnet" means for shoal usage?

From: Stanley Xu <wenhao.xu_at_gmail.com>
Date: Wed, 5 Jan 2011 22:12:45 +0800

Thanks Joseph.

I have made it work after I set the multicast ip address and port.

Best wishes,
Stanley Xu



On Wed, Jan 5, 2011 at 7:41 AM, Joseph Fialli <joe.fialli_at_oracle.com> wrote:

> Stanley,
>
> Thanks for all the information. The telnet information you did verify that
> tcp server was listening.
>
> For discovery, gms relies on multicast udp. We do have a test program to
> assist in
> diagnosing if two machines are seeing each other via multicast. The test
> program is
> strictly Java MulticastSocket.
>
> Here is how to run the test on your two machines:
>
> Open a terminal window on machine A and run
> the following command in shoal/gms workspace.
>
> % ant test-mcastsniffer
>
> Then on another terminal window on machine B, cd into shoal/gms directory
> and run
>
> $ ant test-mcastsender
>
> If the two machines can see each other, you will see the following printed
> on the terminal
> window of the mcast-sniffer terminal window.
>
> test-mcastsniffer:
> [java] Here's some multicast data
> [java]
> [java] Here's some multicast data
> [java]
> [java] Here's some multicast data
> [java]
> [java] Here's some multicast data
> [java]
> [java] Here's some multicast data
> [java]
>
> If no data is printed, then we need to work some on getting them to see
> each other.
> There are many reasons that they may not be able to see each other. When I
> run
> VPN, two terminal windows on same machine do not see each others broadcast
> UNLESS
> I set the IP address to use to be 127.0.0.1. (that is third argument to
> test program denoted below
>
> To customize the Network Interface to use (the above just uses defaults),
> modify the following in build.xml.
>
> <target name="test-mcastsender" depends="build" description="Run
> MulticastSender">
> <java classname="net.MulticastSender" fork="true">
> <classpath>
> <path refid="compile.classpath"/>
> <pathelement location="${dist.dir}/${shoal-gms.jar}"/>
> </classpath>
> <arg value="229.9.1.1"/> <!-- default multicast
> group address -->
> <arg value="2299"/> <!-- default mulicast
> port -->
> <arg value="XXX.YYY.ZZZ.AAA"/> <!-- ip address of network
> interface to use for multicast broadcast -->
> </java>
> </target>
>
> <target name="test-mcastsniffer" depends="build" description="Run
> MulticastSniffer">
> <java classname="net.MulticastSniffer" fork="true">
> <classpath>
> <path refid="compile.classpath"/>
> <pathelement location="${dist.dir}/${shoal-gms.jar}"/>
> </classpath>
> <arg value="229.9.1.1"/> <!-- default multicast group
> address -->
> <arg value="2299"/> <!-- default multicast port -->
> <arg value="XXX.YYY.ZZZ.BBB"/> < !-- ip address of network
> interface to use for multicast receive -->
> </java>
> </target>
>
> -Joe
>
>
>
>
>
> On 1/4/11 4:36 AM, Stanley Xu wrote:
>
> The following is the output of the ifconfig on those two machines:
>
> Machine1
> eth1 Link encap:Ethernet HWaddr 00:A0:D1:EE:B1:09
> inet addr:192.168.11.91 Bcast:192.168.11.255 Mask:255.255.255.0
> inet6 addr: fe80::2a0:d1ff:feee:b109/64 Scope:Link
> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> RX packets:38251006946 errors:0 dropped:246862 overruns:0 frame:0
> TX packets:20934615765 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:1000
> RX bytes:49418086991604 (44.9 TiB) TX bytes:8526692127415 (7.7
> TiB)
> Memory:fac60000-fac80000
>
> lo Link encap:Local Loopback
> inet addr:127.0.0.1 Mask:255.0.0.0
> inet6 addr: ::1/128 Scope:Host
> UP LOOPBACK RUNNING MTU:16436 Metric:1
> RX packets:2892195678 errors:0 dropped:0 overruns:0 frame:0
> TX packets:2892195678 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:0
> RX bytes:23821021433042 (21.6 TiB) TX bytes:23821021433042 (21.6
> TiB)
>
> Machine2
> eth0 Link encap:Ethernet HWaddr F0:4D:A2:01:7E:6E
> inet addr:114.80.69.183 Bcast:114.80.69.191
> Mask:255.255.255.240
> inet6 addr: fe80::f24d:a2ff:fe01:7e6e/64 Scope:Link
> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> RX packets:130743485 errors:0 dropped:0 overruns:0 frame:0
> TX packets:82548770 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:1000
> RX bytes:163177496353 (151.9 GiB) TX bytes:6858432901 (6.3 GiB)
> Interrupt:90 Memory:d6000000-d6012800
>
> eth2 Link encap:Ethernet HWaddr F0:4D:A2:01:7E:72
> inet addr:192.168.11.124 Bcast:192.168.11.255
> Mask:255.255.255.0
> inet6 addr: fe80::f24d:a2ff:fe01:7e72/64 Scope:Link
> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> RX packets:3931753690 errors:0 dropped:0 overruns:0 frame:0
> TX packets:132645337 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:1000
> RX bytes:679219389327 (632.5 GiB) TX bytes:46934167055 (43.7
> GiB)
> Interrupt:106 Memory:da000000-da012800
>
> lo Link encap:Local Loopback
> inet addr:127.0.0.1 Mask:255.0.0.0
> inet6 addr: ::1/128 Scope:Host
> UP LOOPBACK RUNNING MTU:16436 Metric:1
> RX packets:21507 errors:0 dropped:0 overruns:0 frame:0
> TX packets:21507 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:0
> RX bytes:3282262 (3.1 MiB) TX bytes:3282262 (3.1 MiB)
>
>
> I hava add the following code for setting the properties of the GMS
> service:
>
> Properties props = new Properties();
> props.put(ServiceProviderConfigurationKeys.BIND_INTERFACE_ADDRESS,
> ipAddress);
> return (GroupManagementService) GMSFactory.startGMSModule(serverName,
> groupName, GroupManagementService.MemberType.CORE, props);
>
> The ipAddress field is coming from the command line. And it is set to
> 192.168.11.91 on Machine1 and 192.168.11.124 on Machine2.
>
> And I could also use command
> telnet 192.168.11.91 9701
> telnet 192.168.11.124 9701
> on the two machines and get the output like the following:
> Trying 192.168.11.91...
> Connected to hadoopsh11091 (192.168.11.91).
> Escape character is '^]'.
> JXTAHELLO tcp://192.168.11.124:56594 tcp://192.168.11.91:9701urn:jxta:uuid-59616261646162614A787461503250337EA20FB25AC44D0F88B6884346DE904203
> 0 1.1
>
> So I thought it should not be a firewall issue in tcp ports.
>
> Is there anything else I missed to get it work on the two different
> physical machines?
>
> Best wishes,
> Stanley Xu
>
>
>
> On Tue, Jan 4, 2011 at 2:24 PM, Stanley Xu <wenhao.xu_at_gmail.com> wrote:
>
>> Dear All,
>>
>> I am currently trying to use the shoal to make our application running
>> on multiple clusters. I am using the sample code and it works well on the
>> dev machine with two different JVM. But when I put the program to two
>> different machine. It didn't work.
>>
>> Is there any settings or constraints if I wanted to use the shoal to do
>> clustering on two different machine? Shall I set any ip or port in the
>> program? Or I should open a specific port on the firewall?
>>
>> What does the "same subnet" means in the shoal? Does that means the two
>> machine should have the same gateway ip?
>>
>> Thanks.
>>
>> Best wishes,
>> Stanley Xu
>>
>>
>