1 Reply Latest reply on Dec 13, 2005 3:18 AM by alexserbul

    JNDI properties/remote bean problem

    stedo

      hi,

      I am fairly new to JBOSS and I'm running the 4.0.3SP1 server. I have been running a server on my local machine where I have deployed an application and accessed the bean through a stand-alone client. Everything worked fine. Then I moved the server to a remote machine on the same network deployed the bean, and changed the jndi.properties file to reflect the new host. I ran the client and I receive the following:

      Exception in thread "main" javax.naming.CommunicationException [Root exception i
      s java.rmi.ConnectException: Connection refused to host: 127.0.0.1; nested excep
      tion is:
       java.net.ConnectException: Connection refused: connect]
       at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:707)
       at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:572)
       at javax.naming.InitialContext.lookup(Unknown Source)
       at crimeportal.beans.laundry.Client.main(Client.java:41)
      Caused by: java.rmi.ConnectException: Connection refused to host: 127.0.0.1; nes
      ted exception is:
       java.net.ConnectException: Connection refused: connect
       at sun.rmi.transport.tcp.TCPEndpoint.newSocket(Unknown Source)
       at sun.rmi.transport.tcp.TCPChannel.createConnection(Unknown Source)
       at sun.rmi.transport.tcp.TCPChannel.newConnection(Unknown Source)
       at sun.rmi.server.UnicastRef.invoke(Unknown Source)
       at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
       at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:610)
       ... 3 more
      Caused by: java.net.ConnectException: Connection refused: connect
       at java.net.PlainSocketImpl.socketConnect(Native Method)
       at java.net.PlainSocketImpl.doConnect(Unknown Source)
       at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
       at java.net.PlainSocketImpl.connect(Unknown Source)
       at java.net.SocksSocketImpl.connect(Unknown Source)
       at java.net.Socket.connect(Unknown Source)
       at java.net.Socket.connect(Unknown Source)
       at java.net.Socket.<init>(Unknown Source)
       at java.net.Socket.<init>(Unknown Source)
       at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(Unknown S
      ource)
       at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(Unknown S
      ource)
       ... 9 more
      


      The odd thing is that it looks like it is trying to connect to localhost?? Can anyone help??

      Thanks in advance.
      Stephen