1 Reply Latest reply on Nov 23, 2010 2:56 AM by goldmann

    Cann't connect JBoss AS on EC2 Instance through a JMS Client. Please help me it's urgent!!

    ingedeut

      Hello Marek,

       

      i have created an AMI for JBoss ESB and started it. When trying to communicate with the JBoss ESB server through a JMS Client, an error is thrown saying:

       

       

      Exception in thread "main" javax.naming.CommunicationException [Root exception is java.rmi.UnknownHostException: Unknown host: domU-12-31-39-0B-08-62.compute-1.internal; nested exception is: 
           java.net.UnknownHostException: domU-12-31-39-0B-08-62.compute-1.internal]
           at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:780)
           at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:627)
           at javax.naming.InitialContext.lookup(Unknown Source)
           at org.jboss.soa.esb.samples.quickstart.helloworld.test.SendJMSMessage.setupConnection(SendJMSMessage.java:60)
           at org.jboss.soa.esb.samples.quickstart.helloworld.test.SendJMSMessage.main(SendJMSMessage.java:96)
      Caused by: java.rmi.UnknownHostException: Unknown host: domU-12-31-39-0B-08-62.compute-1.internal; nested exception is: 
           java.net.UnknownHostException: domU-12-31-39-0B-08-62.compute-1.internal
           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:667)
           ... 4 more
      Caused by: java.net.UnknownHostException: domU-12-31-39-0B-08-62.compute-1.internal
           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 Source)
           at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(Unknown Source)
           ... 10 more
      

       

       

      Exception in thread "main" javax.naming.CommunicationException [Root exception is java.rmi.UnknownHostException: Unknown host: domU-12-31-39-0B-08-62.compute-1.internal; nested exception is:
      java.net.UnknownHostException: domU-12-31-39-0B-08-62.compute-1.internal]
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:780)
      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:627)
      at javax.naming.InitialContext.lookup(Unknown Source)
      at org.jboss.soa.esb.samples.quickstart.helloworld.test.SendJMSMessage.setupConnection(SendJMSMessage.java:60)
      at org.jboss.soa.esb.samples.quickstart.helloworld.test.SendJMSMessage.main(SendJMSMessage.java:96)
      Caused by: java.rmi.UnknownHostException: Unknown host: domU-12-31-39-0B-08-62.compute-1.internal; nested exception is:
      java.net.UnknownHostException: domU-12-31-39-0B-08-62.compute-1.internal
      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:667)
      ... 4 more
      Caused by: java.net.UnknownHostException: domU-12-31-39-0B-08-62.compute-1.internal
      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 Source)
      at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(Unknown Source)
      ... 10 more

       

      I have opened the port 1099 for rmi in the securtiy group but i still have the problem. In the JMS Client i have used als Hostadresse for the Client the  Public DNS of the EC2 Instance (here is ec2-50-16-52-228.compute-1.amazonaws.com) but in the error i recieve an answer about the private DNS (domU-12-31-39-0B-08-62.compute-1.internal). I cann't undesrtand this.

       

      Is there a specific package which must be added to the .appl file that help to solve this issue?

       

      thanks in advance

       

      --regards

       

      younes