1 Reply Latest reply on Sep 23, 2010 5:29 AM by Wolf-Dieter Fink

    How to set up the Jboss Ejb server in the LAN

    Robin Nee Newbie

      I need to deploy the service in the LAN network-mapping by the router.

      The server is in the LAN,IP of the server  is LAN IP,and IP of the router the Public network IP

      and then I configure the network-mapping at the router.

      The network-mapping works well.

       

      The Jboss version is JBOSS AS 5.1

      The server is not for web.it's a Ejb service .

       

      Now I have tried as following ,but not success.

       

      all the client using the Public network IP to lookup,but not one success.

      1.

      add the binding in run.bat ,-b 0.0.0.0

      it turn out

      could not Resolve the domain name:Test-Server.(Test-Server is the server network-name)

       

      javax.naming.CommunicationException [Root exception is java.rmi.UnknownHostException: Unknown host: QA-server; nested exception is:
          java.net.UnknownHostException: QA-server]
          at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:839)
          at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686)
          at javax.naming.InitialContext.lookup(InitialContext.java:392)
          at com.cithinc.util.SysUtil.lookup(SysUtil.java:157)
          at com.cithinc.LoginFrame$2.run(LoginFrame.java:569)
          at java.lang.Thread.run(Thread.java:619)
      Caused by: java.rmi.UnknownHostException: Unknown host: QA-server; nested exception is:
          java.net.UnknownHostException: QA-server
          at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:598)
          at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:198)
          at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
          at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:110)
          at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
          at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:726)
          ... 5 more
      Caused by: java.net.UnknownHostException: QA-server
          at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177)
          at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
          at java.net.Socket.connect(Socket.java:519)
          at java.net.Socket.connect(Socket.java:469)
          at java.net.Socket.<init>(Socket.java:366)
          at java.net.Socket.<init>(Socket.java:180)
          at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
          at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
          at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:595)

       

      2.

      add args to run.bat

      -Djava.rmi.server.hostname=xxx.xxx.xxx.xxx^
      -Dremoting.bind_by_host=false ^

      add the binding in run.bat ,-b 0.0.0.0

      t turn out

      could not Resolve the server xxx.xxx.xxx.xxx,.(xxx.xxx.xxx.xxx is the LAN IP)

       

      javax.naming.CommunicationException [Root exception is java.rmi.ConnectException: Connection refused to host: 10.11.122.88; nested exception is:
          java.net.ConnectException: Connection timed out: connect]
          at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:839)
          at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686)
          at javax.naming.InitialContext.lookup(InitialContext.java:392)
          at com.cithinc.util.SysUtil.lookup(SysUtil.java:157)
          at com.cithinc.LoginFrame$2.run(LoginFrame.java:569)
          at java.lang.Thread.run(Thread.java:619)
      Caused by: java.rmi.ConnectException: Connection refused to host: 10.11.122.88; nested exception is:
          java.net.ConnectException: Connection timed out: connect
          at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:601)
          at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:198)
          at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
          at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:110)
          at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
          at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:726)
          ... 5 more
      Caused by: java.net.ConnectException: Connection timed out: connect
          at java.net.PlainSocketImpl.socketConnect(Native Method)
          at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
          at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
          at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
          at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
          at java.net.Socket.connect(Socket.java:519)
          at java.net.Socket.connect(Socket.java:469)
          at java.net.Socket.<init>(Socket.java:366)
          at java.net.Socket.<init>(Socket.java:180)
          at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
          at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
          at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:595)

       

      How can i do?

      Help me..