1 Reply Latest reply on Feb 20, 2006 1:27 PM by Jacques Leplat

    JBoss Linux Woes

    Jacques Leplat Newbie

      I have a project that runs fine on Windows & JBoss (JBoss_4_0_3_SP1), but if I copy it to Linux (also JBoss_4_0_3_SP1), the servlet can't lookup the EJB (EJB3 stateless bean). It keeps on throwing a NameNotFoundException. Can anyone shed some light on this?

      I have started JBoss to use IPv4 in the JVM, to fix the JBoss startup problems with IPv6.

      The init portion of the servlet thows the exception, here's the init():

      public void init() throws ServletException{
      try {
      Context context = new InitialContext();
      NamingEnumeration e = context.list("");
      while (e.hasMoreElements()) {
      NameClassPair p = (NameClassPair) e.nextElement();
      System.out.println("....>" + p.getName() + " " + p.getClassName());
      }
      statelessBean = (TestStateless) context.lookup(TestStateless.class.getName());
      }
      catch (Exception ex) {
      ex.printStackTrace();
      }
      }
      Here's the console output:
      16:48:39,883 INFO [STDOUT] ....>XAConnectionFactory org.jboss.mq.SpyXAConnectionFactory
      16:48:39,884 INFO [STDOUT] ....>TopicConnectionFactory org.jboss.naming.LinkRefPair
      16:48:39,884 INFO [STDOUT] ....>UserTransactionSessionFactory $Proxy30
      16:48:39,884 INFO [STDOUT] ....>UIL2ConnectionFactory javax.naming.LinkRef
      16:48:39,884 INFO [STDOUT] ....>UIL2XAConnectionFactory javax.naming.LinkRef
      16:48:39,884 INFO [STDOUT] ....>HAPartition org.jnp.interfaces.NamingContext
      16:48:39,884 INFO [STDOUT] ....>QueueConnectionFactory org.jboss.naming.LinkRefPair
      16:48:39,884 INFO [STDOUT] ....>topic org.jnp.interfaces.NamingContext
      16:48:39,884 INFO [STDOUT] ....>queue org.jnp.interfaces.NamingContext
      16:48:39,885 INFO [STDOUT] ....>HASessionState org.jnp.interfaces.NamingContext
      16:48:39,885 INFO [STDOUT] ....>ConnectionFactory org.jboss.mq.SpyConnectionFactory
      16:48:39,886 INFO [STDOUT] ....>UserTransaction org.jboss.tm.usertx.client.ClientUserTransaction
      16:48:39,886 INFO [STDOUT] ....>jmx org.jnp.interfaces.NamingContext
      16:48:39,887 INFO [STDOUT] ....>UILXAConnectionFactory javax.naming.LinkRef
      16:48:39,887 INFO [STDOUT] ....>UILConnectionFactory javax.naming.LinkRef
      16:48:39,942 INFO [STDOUT] javax.naming.NameNotFoundException: com.j3ltd.test.ejbs.TestStateless not bound
      16:48:39,943 INFO [STDOUT] at org.jnp.server.NamingServer.getBinding(NamingServer.java:514)
      16:48:39,943 INFO [STDOUT] at org.jnp.server.NamingServer.getBinding(NamingServer.java:522)
      16:48:39,944 INFO [STDOUT] at org.jnp.server.NamingServer.getObject(NamingServer.java:528)
      16:48:39,944 INFO [STDOUT] at org.jnp.server.NamingServer.lookup(NamingServer.java:281)
      16.... and so on