8 Replies Latest reply on May 7, 2004 5:20 PM by kenroberts

    Jboss only works with local clients on Linux

    luigifonti

      I've a crazy problem.
      Installed Jboss-3.2 on two different machines: the first one with Windows XP, the other one with Linux Mandrake 10.
      Create a test application which seems to work proper on both machines with local clients.
      The problem is when I try to use clients on remote machines: the Windows version works fine, while the Linux version doesn't supply its EJB's to remote clients. The returned Exception is:

      java.rmi.NoSuchObjectException : no such object in table

      Note that the Linux machine is perfectly reachable from the outer world, all the servers (http, mysql...) work properly; the jmx-console is reachabe too, ad indicates that the required class is bound.

        • 1. Re: Jboss only works with local clients on Linux
          fabzz

          I encounter exactly the same problem :

          linux client - same machine server : works fine
          linux client - win XP server : works fine
          win XP client - winXP server : works fine
          win XP client - linux server : java.rmi.NoSuchObjectException : no such object in table

          I agree with Luigi this is completly crazy !

          Maybe that this is related to the way the retrieval of the context is done :

          //start code
          InitialContextFactory icf = new InitialContextFactory();
          Context context = icf.getInitialContext(serverType,host,port);
          //end code

          Maybe Adrian could give us some pointers ?

          Fabzz

          • 2. Re: Jboss only works with local clients on Linux
            triathlon98

            Maybe you have a firewall running on your system which is blocking all remote access...

            Joachim

            • 3. Re: Jboss only works with local clients on Linux
              tthiele

              I had the same 'crazy' problem. The solution was to configue the ns resolution correctly. It seems that the reverse lookup needs to be consistent with the forward lookup. Otherwise JNDI doesn't work properly. I think that would explain the 'asymmetric' behaviour of your system.

              • 4. Re: Jboss only works with local clients on Linux
                fabzz

                Thanks for your reply

                In fact no firewall is running between client and servers.

                We do not use a DNS at all. We're using /etc/hosts file on win and linux machines. Could this be the cause of the problem ?
                When pinging using names from both client and servers names are well resolved.

                • 5. Re: Jboss only works with local clients on Linux
                  philc

                  I have a similar problem.
                  From linux to linux the application works fine. But when I access JBoss running on Linux from other machines running WinXP and Win2K the client hangs or fails to deserialize Objects.

                  Any Ideas?
                  All machine are running Java 1.4.2_04 specific to their OS.
                  Is it a Java version problem? A Socket problem?
                  Did you solve this issue?

                  Philippe

                  • 6. Re: Jboss only works with local clients on Linux
                    trygve

                    I've also had the same problem when running the JBoss server on Linux and a client looking up any object on Windows. The solution was to change the /etc/hosts file from:

                    127.0.0.1 <my-host-name> localhost.localdomain localhost

                    to:

                    127.0.0.1 localhost.localdomain localhost
                    <my-ip> <my-host-name>

                    After editing the hosts file I restarted JBoss, and everything worked all fine.

                    Trygve

                    • 7. Re: Jboss only works with local clients on Linux
                      birwin

                      We had a similar problem and changed some params we pass to the JVM in our go.sh file:

                      # FOR REMOTE INTERFACE CALLS TO WORK, THIS LINE MUST BE UNCOMMENTED
                      # AND THE IP ADDRESS OF THE LOCAL MACHINE PUT IN
                      # export JBOSS_OPTS="-Xms64m -Xmx640m -Djava.rmi.server.hostname=<IP ADDRESS>"

                      $JAVACMD $JBOSS_OPTS -classpath $CLASSPATH org.jboss.Main -c ../server/default "$@"

                      • 8. Re: Jboss only works with local clients on Linux
                        kenroberts

                        I just installed JBoss 3.2.3 on linux, and it instantly worked fine from a windows box. My only issue is that my default context isn't working the same way as it was on 3.0.6. (previous thread, same forum)

                        I have never run into this myself, but I have heard a claim that a hosts file on windows can be case sensitive in some cases. Regardless, you have a name server in your linux box already, and it seems you're doing static addresses. You should be able to set up DNS in a snap, or go somewhere like http://www.zoneedit.com to get free gui-driven dns, if you're using public addresses.

                        I don't give much credence to the case sensitive hosts file claim, but I have had extremely recent luck getting JBoss to run on linux and be accessible from windows, so I posted this here.