Re: Disabling Multicast to run multiple JavaSpace

Juan Ramirez <[email protected]>
Newsgroups gmane.comp.java.sun.javaspaces
Organization Sun Microsystems
Message-ID <[email protected]>
The traffic you are seing is being generated by the LookupDiscoveryManager used
by Reggie.  I am assumming the snippets you provided come from the same output,
so the output listing the network interfaces is not coming directly from Reggie,
but rather from the LookupDiscovery that LookupDiscoveryManager uses. It seems
to me that what snoop is reporting is LookupDiscovery joining the multicast
announcement group.  If you want to avoid this output, try adding the following
to transient-reggie.config

net.jini.discovery.LookupDiscovery {
    multicastInterfaces = new NetworkInterface[]{};
}

You will probably have to do something similar for outrigger's configuration file.

timur mehrvarz wrote:
> Hello,
>
> we're trying to disable multicast traffic, so that we can run two (or
> more) JavaSpaces in parallel in the same LAN.
>
> Despite the fact that we have disabled multicast usage (zero length
> array for multicastInterfaces), JINI discovers all configured
> interfaces:
>
> CONFIG: LookupDiscovery - multicast network interface(s): [name:qfe3
> (qfe3) index: 4 addresses:
> /10.215.203.68;
> , name:qfe2 (qfe2) index: 3 addresses:
> /10.215.203.66;
> /10.215.203.67;
> , name:hme0 (hme0) index: 2 addresses:
> /10.215.52.192;
> , name:lo0 (lo0) index: 1 addresses:
> /127.0.0.1;
> ]
>
> [.....]
> Mar 22, 2005 11:23:16 AM com.sun.jini.reggie.RegistrarImpl init
> CONFIG: multicast disabled
> Mar 22, 2005 11:23:16 AM net.jini.config.AbstractConfiguration
> getEntryInternal
> FAILED: ConfigurationFile@120cc56{transient-reggie.config}, component
> com.sun.jini.reggie, name multicastRequestSubjectChecker: entry not
> found
> [.....]
>
> Obviously, multicast is disabled.
>
> Nevertheless:
>
> root@wherever#snoop -d qfe3 net 224.0.1.84 or net 224.0.1.85
> Using device /dev/qfe (promiscuous mode)
>   wherever-qfe3 -> JINI-ANNOUNCEMENT.MCAST.NET IP  D=224.0.1.84
> S=10.215.203.68 LEN=28, ID=9325
>            app1 -> JINI-ANNOUNCEMENT.MCAST.NET IP  D=224.0.1.84
> S=10.215.203.66 LEN=28, ID=40772
>            app1 -> JINI-ANNOUNCEMENT.MCAST.NET IP  D=224.0.1.84
> S=10.215.203.66 LEN=28, ID=40773
>
> Multicast announcements are being sent out.
>
> Is there any way to totally disable the multicast traffic?
>
> Cheers,
> Timur
>
>
> Startup: ===
>
> #!/bin/sh
> /apps/java/j2sdk/current/bin/java
> -Djava.util.logging.config.file=reggie.log.properties
> -Djava.security.policy=services.all.policy
> -Djsk.lib=/apps/jini/jini2_0_002/lib -jar
> /apps/jini/jini2_0_002/lib/start.jar t1.config
>
> ===
>
> t1.config: ===
> import com.sun.jini.start.NonActivatableServiceDescriptor;
> import com.sun.jini.start.ServiceDescriptor;
> import com.sun.jini.config.ConfigUtil;
>
> com.sun.jini.start {
>      private static reggieconf = "transient-reggie.config";
>
>      // Discovery Group to use
>      private static group = "${user.name}";
>
>      private static httpdPort = "8090";
>      private static codebaseBase = ConfigUtil.concat(new Object[] {
>          "http://", ConfigUtil.getHostName(), ":", httpdPort, "/"});
>
>      private static policy = "services.all.policy";
>      private static classpathBase = ConfigUtil.concat(new Object[] {
>           "${jsk.lib}","${/}"});
>
>      static serviceDescriptors = new ServiceDescriptor[] {
>
>          // httpd
>          new NonActivatableServiceDescriptor(
>              "",
>              policy,
>              ConfigUtil.concat(new Object[] {classpathBase,
> "tools.jar"}),
>              "com.sun.jini.tool.ClassServer",
>              new String[]{"-port", httpdPort, "-dir", "${jsk.lib}",
> "-verbose"}),
>          // Reggie (lookup service)
>          new NonActivatableServiceDescriptor(
>              ConfigUtil.concat(new Object[] {codebaseBase,
> "reggie-dl.jar"}),
>              policy,
>              ConfigUtil.concat(new Object[] {classpathBase,
> "reggie.jar"}),
>              "com.sun.jini.reggie.TransientRegistrarImpl",
>              new String[] { reggieconf })
>      };
> }
> ===
>
> transient-reggie.config: ===
> import net.jini.jeri.BasicILFactory;
> import net.jini.jeri.BasicJeriExporter;
> import net.jini.jeri.tcp.TcpServerEndpoint;
>
> com.sun.jini.reggie {
>
>      multicastInterfaces = new java.net.NetworkInterface[]{};
>      initialMemberGroups = new String[] { "cb-member-group" };
> }
> ===
>
> ===========================================================================
> To unsubscribe, send email to [email protected] and include in the body
> of the message "signoff JAVASPACES-USERS".  For general help, send email to
> [email protected] and include in the body of the message "help".
>
> To view past JAVASPACES-USERS postings, please see:
> http://archives.java.sun.com/archives/javaspaces-users.html
>
> JDC members can download the JavaSpaces(tm) Technology from:
> http://developer.java.sun.com/developer/products/jini/

===========================================================================
To unsubscribe, send email to [email protected] and include in the body
of the message "signoff JAVASPACES-USERS".  For general help, send email to
[email protected] and include in the body of the message "help".

To view past JAVASPACES-USERS postings, please see:
http://archives.java.sun.com/archives/javaspaces-users.html

JDC members can download the JavaSpaces(tm) Technology from:
http://developer.java.sun.com/developer/products/jini/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.