1 Reply Latest reply on Dec 25, 2009 3:03 PM by Ron Sigal

    Problem with multiple ethernet adapters

    Mayank Mittal Novice

      Setup
      ---------
      Server Name : Server001

      IBM Blade Server
      -> Two Ethernet adapters eth0 (100 Mbps) and eth1 (1000 Mbps)
      -> eth0: 150.158.73.49
      -> eth1: 192.168.200.49

      Debian 5 Installed
      Jboss 4.2.3
      Jboss Remoting 2.4.0 SP1
      Jboss Messaging 1.4.2

      Host file entry:

      127.0.0.1 localhost
      150.158.73.49 Server001 Server001
      


      Scenario
      -----------

      Jboss is bound to "Server001"

      lookup Code

      final Properties props = new Properties();
       props.put(Context.INITIAL_CONTEXT_FACTORY, "org.jnp.interfaces.NamingContextFactory");
       props.put(Context.URL_PKG_PREFIXES, "org.jboss.naming:org.jnp.interfaces");
       props.put("jnp.sotimeout", "2000");
       props.put("jnp.timeout", "2000");
       props.put(Context.PROVIDER_URL, java.lang.System.getProperty("bind.address") + ":1100"); // HA-JNDI port.
      
      
       String partitionName = java.lang.System.getProperty("jboss.partition.name", java.lang.System.getenv("COMPUTERNAME") + "_PARTITION");
       partitionName = partitionName.toUpperCase();
      
       // for auto discovery through partition name
       props.put(NamingContext.JNP_PARTITION_NAME, partitionName);
       props.put(NamingContext.JNP_DISCOVERY_GROUP, "230.0.0.4");// Default
       props.put(NamingContext.JNP_DISCOVERY_PORT, "1102");// Default
       props.put(NamingContext.JNP_DISABLE_DISCOVERY, "false");


      Problem
      ---------

      now the problem is, some time we have seen that, Jboss starts normally without any exception and is looking at eth0 but suddently it starts looking up at eth1, thus unable to lookup deployed services.