Rmi problem

Hello,
I am working with melilta and amilcare both written in java.
My problem is when I try to run the melitaserver it shows the error message:
"Melita startup script
Using AMILCARE_HOME: "."
"D:\j2sdk\bin\java" -Xmx200M -Djava.library.path=./runtime -cp "./lib/melita.jar
;./lib/jRegistryKey.jar;D:\j2sdk/lib/tools.jar;./lib/jena.jar;./lib/icu4j.jar;./
lib/gate.jar;./lib/guk.jar;./lib/amilcare.jar" melitaserver.MelitaServer
Rmiregistry located at D:\Program Files\Java\jre1.5.0_05\bin\rmiregistry.exe and
launched !
Information found in path: file:/D:/Documents%20and%20Settings/Dena/Desktop/meli
ta/melita2.0/lib/melita.jar
Amilcare being initialised ...
Amilcare Server exception: error during JRMP connection establishment; nested ex
ception is:
java.net.SocketTimeoutException: Read timed out
java.rmi.ConnectIOException: error during JRMP connection establishment; nested
exception is:
java.net.SocketTimeoutException: Read timed out
at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:274
at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:171)
at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:313)
at sun.rmi.registry.RegistryImpl_Stub.rebind(Unknown Source)
at java.rmi.Naming.rebind(Naming.java:160)
at melitaserver.MelitaServer.main(MelitaServer.java:149)
Caused by: java.net.SocketTimeoutException: Read timed out
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(SocketInputStream.java:129)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:183)
at java.io.BufferedInputStream.read(BufferedInputStream.java:201)
at java.io.DataInputStream.readByte(DataInputStream.java:331)
at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:215
... 5 more
Can anyone help me?
Best regards

Hello!
Have you figured out the cause of problem for that exception? I also encountered that, the difference only is I use IBM Websphere.
What did you do to solve it? Hope you can reply.
Thanks!

Similar Messages

  • Please help with an RMI problem

    Hi,
    This is probably a really simple problem which i can't spot, but i have the folloing 'HelloWorld' RMI program:
    The Client Program:
    import java.rmi.*;
    public class HelloClient {
         public static void main(String args[]) {
              if(System.getSecurityManager() == null) {
                   System.setSecurityManager(new RMISecurityManager());
              try {
                   HelloInterface obj = (HelloInterface)Naming.lookup("/HelloServer");
                   String message = obj.sayHello();
                   System.out.println(message);
                   Thread.sleep(10000);
              } catch (Exception e) {
                   System.out.println("HelloClient exception: " + e);
    }The Remote Interface:
    public interface HelloInterface extends java.rmi.Remote {
         public String sayHello() throws java.rmi.RemoteException;
    }The Server Program:
    import java.io.*;
    import java.rmi.*;
    import java.rmi.server.*;
    import java.util.Date;
    public class HelloServer extends UnicastRemoteObject implements HelloInterface {
         public HelloServer() throws RemoteException {
              super();
         public String sayHello() throws RemoteException {
              return "Hello World, the current system time is " + new Date();
    }And finally the class which binds the object to the registery:
    import java.rmi.*;
    public class RegisterIt {
         public static void main(String args[]) {
              try {
                   HelloServer obj = new HelloServer();
                   System.out.println("Object instantiated: " + obj);
                   Naming.rebind("/HelloServer", obj);
                   System.out.println("HelloServer bound to registery");
              } catch (Exception e) {
                   System.out.println(e);
    }Now, this program works fine on my computer at home(XP!!!!!) but when i try to run it on the computers in college which run NT, it comes up with the following exceptions when i try to run RegisterIt:
    Java.rmi.UnmarshalException: error unmarshalling arguments; nested exception is:
    Java.lang.ClassNotFoundException: HelloServer_StubThis is saying that it cannot find the stub which is generated, but i use the folloing .bat file to load up the program:
    echo Creating remote object skelton classes....
    rmic -d . HelloServer
    start rmiregistry -J-Djava.security.policy=test.policy
    start java RegisterIt
    start java -Djava.security.policy=test.policy HelloClientThe stub is definitely created(it worked at home and i have checked in the directory and there are clearly the files HelloServer_Stub.class and HelloServer_Skel.class). The PATH is set correctly otherwise the registery would not be able to run correctly etc and therefore i am completely stuck as to why it doesn't work.
    Please help as it is very important for me.
    Many Thanks
    Cath

    I did not have any problem with Windows 2000 at all but only with Windows XP (and to think XP is a 2000 hybrid!).
    I have the same error: a ClassNotFoundException on the stub file.
    Any help will be appreciated. Thanks.

  • RMI Problem with rebind()

    created files as below. All compiled successfully.
    ran <rmic -v1.1 -d %cp% -classpath %cp% server.TempServerImpl> from command window.
    this generated a stub file called TempServerImpl_Stub.class
    I launched the rmiRegistry
    To make the remote object available to recieve mathod calls from clients I run TempServerImpl.class
    But ..... when I run TempServerImpl I get the exception "java.rmi.ServerException: RemoteException occurred in server thread; nested exception is: "
    AND..... my stub class is deleted without any warning!!!
    if I comment out the line "Naming.rebind( serverObjectName, tempServer );" after I generate the stub class then TempServerImpl runs without throwing any exception but this must be included to bind my remote server object to the RMI registry.
    Any ideas what Im missing?
    import java.rmi.RemoteException;
    import java.rmi.server.UnicastRemoteObject;
    import java.net.URL;
    import java.rmi.Remote;
    import java.rmi.Naming;
    public class TempServerImpl extends UnicastRemoteObject implements TempServer{
       public TempServerImpl() throws RemoteException {
          super();
       public Info getInfo() throws RemoteException{
          return new Info("some temperature data returned");
       public static void main( String args [] ) throws Exception{
          TempServerImpl tempServer = new TempServerImpl();
          String serverObjectName = "//localhost/TempServer";
          Naming.rebind( serverObjectName, tempServer );
    //************ Remote Interface
    import java.rmi.*;
    import java.rmi.RemoteException;
    public interface TempServer extends Remote {
      public Info getInfo() throws RemoteException;
    import java.io.Serializable;
    public class Info implements Serializable{
       private String data;
       public Info(String data){
          this.data = data;
       public String toString(){
          return this.data;
    [\code]                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    Are you sure that the stub is being deleted, or is it just that the exception message says it can't be found. If it's the latter it might be that the stub is not in the class path of either the commandline running the rmi registry or the commandline running the TempServerImpl. However as you are running this i assume it ok.
    The code looks fine, The problem is something to do with classpaths ect.

  • Unexpected RMI problem

    Hi,
    I have unexpected problem with RMI.
    I wrote an application with several server modules and client modules.
    Two server modules use RMI to expose their methods for client and reciprocal exchange. These servers are in the same directory and use the same RMI service. One server starts before other and lunch RMI service. After that it binds its methods. The second server get RMI service , search methods of first server and bind its methods.
    The first time that servers started, they ran correctly for months.
    When I stopped servers for maintenance of other module, without change servers, I had the problem.
    First server started correctly and RMI started correctly too. When second server started, it ran correctly but first server hangs without errors from RMI. I tried to start servers for an hours but nothing changed.
    After 12 hours I tried to start servers and they ran correctly at first trial.
    My questions are: why the same code has this different behaviour? What was it changed in those 12 hours?
    Code:
    Server1: main
    Registry registry = null;
    try {
    registry = LocateRegistry.createRegistry(Integer.valueOf(Port));
    } catch (RemoteException e) {
              e.printStackTrace();
    Server1MethodInterface server1RMIinterface = (server1MethodInterface) UnicastRemoteObject.exportObject(server1RMI,Integer.parseInt(portRMI));
    registry.rebind("server1RMI", server1RMIinterface);
    end main
    Server2: constructor
    try {
         registry = LocateRegistry.getRegistry(ipServer1,Integer.parseInt(Server1RegistryPort.trim()));
    server1MethodInterface = (server1MethodInterface)registry.lookup("server1RMI ");
    } catch (RemoteException e) {
         e.printStackTrace();
    Main
    Server2 server2 = new Server2 (filePath);
    CheckLogin serverLogin = new CheckLogin(filePath, server2);
    LoginInterface loginInterface = (LoginInterface) UnicastRemoteObject.exportObject(serverLogin, server2.getPortRMI());
    server2.registry.rebind("Login", loginInterface);
    Communication communications = new Communication(server2);
    CommunicationsInterface communicationInterface = (CommunicationsInterface) UnicastRemoteObject.exportObject(communications, server2.getPortaRMI());
    server2.registry.rebind("Communications", communicationInterface);
    ……….

    Hi,
    I have unexpected problem with RMI.
    I wrote an application with several server modules and client modules.
    Two server modules use RMI to expose their methods for client and reciprocal exchange. These servers are in the same directory and use the same RMI service. One server starts before other and lunch RMI service. After that it binds its methods. The second server get RMI service , search methods of first server and bind its methods.
    The first time that servers started, they ran correctly for months.
    When I stopped servers for maintenance of other module, without change servers, I had the problem.
    First server started correctly and RMI started correctly too. When second server started, it ran correctly but first server hangs without errors from RMI. I tried to start servers for an hours but nothing changed.
    After 12 hours I tried to start servers and they ran correctly at first trial.
    My questions are: why the same code has this different behaviour? What was it changed in those 12 hours?
    Code:
    Server1: main
    Registry registry = null;
    try {
    registry = LocateRegistry.createRegistry(Integer.valueOf(Port));
    } catch (RemoteException e) {
              e.printStackTrace();
    Server1MethodInterface server1RMIinterface = (server1MethodInterface) UnicastRemoteObject.exportObject(server1RMI,Integer.parseInt(portRMI));
    registry.rebind("server1RMI", server1RMIinterface);
    end main
    Server2: constructor
    try {
         registry = LocateRegistry.getRegistry(ipServer1,Integer.parseInt(Server1RegistryPort.trim()));
    server1MethodInterface = (server1MethodInterface)registry.lookup("server1RMI ");
    } catch (RemoteException e) {
         e.printStackTrace();
    Main
    Server2 server2 = new Server2 (filePath);
    CheckLogin serverLogin = new CheckLogin(filePath, server2);
    LoginInterface loginInterface = (LoginInterface) UnicastRemoteObject.exportObject(serverLogin, server2.getPortRMI());
    server2.registry.rebind("Login", loginInterface);
    Communication communications = new Communication(server2);
    CommunicationsInterface communicationInterface = (CommunicationsInterface) UnicastRemoteObject.exportObject(communications, server2.getPortaRMI());
    server2.registry.rebind("Communications", communicationInterface);
    ……….

  • RMI Problem --   java.rmi.UnmarshalException:

    I am having a client and a server.... when i am trying to bring the client into server. but when i am doing it... i am getting an exception as below as...
    java.rmi.UnmarshalException: Error unmarshaling return header; nested exception is:
         java.io.EOFException
         at sun.rmi.transport.StreamRemoteCall.executeCall(Unknown Source)
         at sun.rmi.server.UnicastRef.invoke(Unknown Source)
         at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
         at java.rmi.Naming.lookup(Unknown Source)
         at hsmsgui.rmtmgmt.RmtMgmtHandler.contactClient(RmtMgmtHandler.java:176)
         at hsmsgui.display.AddClientWzd.onFinishBtnClicked(AddClientWzd.java:488)
         at hsmsgui.display.AddClientWzd.actionPerformed(AddClientWzd.java:346)
         at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
         at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
         at java.awt.Component.processMouseEvent(Unknown Source)
         at javax.swing.JComponent.processMouseEvent(Unknown Source)
         at java.awt.Component.processEvent(Unknown Source)
         at java.awt.Container.processEvent(Unknown Source)
         at java.awt.Component.dispatchEventImpl(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Window.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
         at java.awt.Dialog$1.run(Unknown Source)
         at java.awt.Dialog$3.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.awt.Dialog.show(Unknown Source)
         at hsmsgui.display.AddClientAction.actionPerformed(AddClientAction.java:38)
         at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
         at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
         at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
         at java.awt.Component.processMouseEvent(Unknown Source)
         at javax.swing.JComponent.processMouseEvent(Unknown Source)
         at java.awt.Component.processEvent(Unknown Source)
         at java.awt.Container.processEvent(Unknown Source)
         at java.awt.Component.dispatchEventImpl(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Window.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.run(Unknown Source)
    Caused by: java.io.EOFException
         at java.io.DataInputStream.readByte(Unknown Source)
         ... 60 more
    can any one help me out to solve this problem.......

    Thanks for ur reply...Now i' m getting the access denied problem..
    I am able to create the rmi registry successfully on the server, Then Binding is also done successfully. but when i try to connect the client to the server the exception is thrown Please help me..
    TEST - client PC name.
    java.security.AccessControlException: access denied (java.net.SocketPermission TEST resolve)
         at java.security.AccessControlContext.checkPermission(Unknown Source)
         at java.security.AccessController.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkConnect(Unknown Source)
         at java.net.InetAddress.getAllByName0(Unknown Source)
         at java.net.InetAddress.getAllByName0(Unknown Source)
         at java.net.InetAddress.getAllByName(Unknown Source)
         at java.net.InetAddress.getByName(Unknown Source)
         at java.net.InetSocketAddress.<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)
         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.newCall(Unknown Source)
         at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
         at java.rmi.Naming.lookup(Unknown Source)
         at hsmsgui.rmtmgmt.RmtMgmtHandler.contactClient(RmtMgmtHandler.java:176)
         at hsmsgui.display.AddClientWzd.onFinishBtnClicked(AddClientWzd.java:488)
         at hsmsgui.display.AddClientWzd.actionPerformed(AddClientWzd.java:346)
         at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
         at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
         at java.awt.Component.processMouseEvent(Unknown Source)
         at javax.swing.JComponent.processMouseEvent(Unknown Source)
         at java.awt.Component.processEvent(Unknown Source)
         at java.awt.Container.processEvent(Unknown Source)
         at java.awt.Component.dispatchEventImpl(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Window.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
         at java.awt.Dialog$1.run(Unknown Source)
         at java.awt.Dialog$3.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.awt.Dialog.show(Unknown Source)
         at hsmsgui.display.AddClientAction.actionPerformed(AddClientAction.java:38)
         at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
         at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
         at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
         at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
         at java.awt.Component.processMouseEvent(Unknown Source)
         at javax.swing.JComponent.processMouseEvent(Unknown Source)
         at java.awt.Component.processEvent(Unknown Source)
         at java.awt.Container.processEvent(Unknown Source)
         at java.awt.Component.dispatchEventImpl(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
         at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
         at java.awt.Container.dispatchEventImpl(Unknown Source)
         at java.awt.Window.dispatchEventImpl(Unknown Source)
         at java.awt.Component.dispatchEvent(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.run(Unknown Source)

  • Unable to create application module.  JNID/RMI problem?

    Hi forum,
    I've got an ADF/OC4J application deployed and running successfully but sometimes the following error comes up:
    JBO-30003: The application pool (com.miempresa.AppModuleLocal) failed to checkout an application module due to the following exception:
    oracle.jbo.JboException: JBO-29000: Unexpected exception caught:
    oracle.jbo.JboException, msg=JBO-29000: Unexpected exception caught: oracle.jbo.JboException, msg=JBO-25222: Unable to create application module.     at
    oracle.jbo.common.ampool.ApplicationPoolImpl.doCheckout(ApplicationPoolImpl.java:2002)     
    In stack trace details we can found:
    java.lang.Thread.run(Thread.java:595)## Detail 0 ##javax.naming.NameNotFoundException: com.miempresa.AppModule not found          
    at com.evermind.server.rmi.RMIServerContext.lookup(RMIServerContext.java:207)          at
    com.evermind.server.ApplicationContext.unprivileged_lookup(ApplicationContext.java:255)          at
    com.evermind.server.ApplicationContext.lookup(ApplicationContext.java:195)          at
    javax.naming.InitialContext.lookup(InitialContext.java:351)          at
    oracle.jbo.common.ampool.DefaultConnectionStrategy.createApplicationModule(DefaultConnectionStrategy.java:136)
    Due to "NameNotFoundException", it seems to be reasonable to say that it's a JNDI problem. When application module is looked up through JNDI it's not found, so exeception is thrown. However, this doesn't happen frequently but occasionally. Why? What am I doing wrong?
    Thanks in advance for your help.
    Luis Serrano.

    Any ideas?

  • Deploying RMI  problem...

    Hi, i`m new at RMI stuff, I`ve been through may problems at this, but I reached the point I can`t to any more.
    Using the example of the "JAVA CONTINUED TUTORIAL", I reached to the point of starting the server.
    I do set the CLASSPATH, and build the "java.policy" files for security.
    I`m able to compile stub classes too, and put the in the JAR file.
    But when I reach to this point:
    java -Djava.rmi.server.codebase=file:c:\jdk1.3\bin/ /*THAT�S MY PATH*/
    -Djava.security.policy=java.policy
    engine.ComputeEngine
    The app throws this Exception:
    ComputeEngine exception: access denied (java.net.SocketPermition host resolve)
    java.security.AccesControlContext.checkPermission .....
    at engine.ComputeEngine main( COmputeEngine java:25).
    So I`ll show my 25 line:
    ***** class ComputeEngine ****
    public static void main(String[] args) {
    if (System.getSecurityManager() == null) {
    System.setSecurityManager(new RMISecurityManager());
    String name = "\\jdk1.3\\bin\\";
    try {
    Compute engine = new ComputeEngine();
    Naming.rebind(name, engine); /* LINE 25*/
    System.out.println("ComputeEngine bound");
    } catch (Exception e) {
    System.err.println("ComputeEngine exception: " + e.getMessage());
    e.printStackTrace();
    I�m not that stupid for not realise that the "name" variable, is not receibing a good path, but what would the sintacticaly and semantically good to put there???? I mean, should that path exist?? (it does actually), is it badly written???
    Thanks
    Thanks.

    You're trying to start the server, right? After launching your rmiregistry?
    You do in fact have a java.policy file, right??
    (specified at the top of:
    http://java.sun.com/docs/books/tutorial/rmi/running.html
    I recall having a permission problem at first and I resolved it I belive by defining this file and having it in the directory I was running 'java ... engine.ComputeEngine' from.
    Hope that helped. I'm encountering a similiar problem when trying to run my client, but I have my server up and running (it binded succesfully).

  • RMI: problem with static context

    I'm trying to do my first RMI application. I have a strange problem. That is I get an error says:
    "non-static method authenticate(String userid, String password) cannot be referenced from a static context". The problem is that the context that I call the method is not static. here is the code that I've implementet (or lets say: trying to implement).
         public Session getSession(String userid, String password) {
              Session     session = null;;
              boolean authenticated     = UserManager.authenticate(userid, password);
              if( authenticated ){
                   try{
                        session = new Session();
                        session.setSessionId(s_next_session_id);
                   }catch(java.rmi.RemoteException e){
                        e.printStackTrace();
                        System.err.println(e.toString());
              } else {
                   // throw Exception();
              return (session);
    What am I missing here. The context (getSession()) is not static, neither is my method in UserManager. What is wrong? Can anybody help me.
    Thanks in advance.

    ignore this. I solve the problem

  • Applet + rmi problem

    I am makinga cards game using rmi .
    When I start my applet , my paint method doesnt run on some clients. Sometimes it doesnt run on all.
    And what is bothering me is the asynchronous behaviour(if I am thinking right) is that when the applet starts
    I register it with the server and the server invokes a remote method on the client. Now which method runs first , the paint() or the remote method. What if both run simultaenoulsy ? is that a problem?
    Also the buttons I show o nthe applet(this is another remote method invoked fro mthe server) only appears after I resize the applet .
    Any ideas?
    thanks

    just use ctrl+a to mark the code and the ctrl+c to copy it. then focus on the textfield you want to paste into and hit ctrl+v...
    thats it ;)

  • RMI Problems with WL 6 and JDK1.3

    I have been working on converting an existing RMI Service- Client
    Application to use Weblogic 6.0. All the rmi services run in an
    external VM seperate from the WL server. This setup works fine with
    plain RMI, I have converted this to WL and JNDI. I get the following
    error after a few connections to the service have been made. It always
    happens.
    <Feb 18, 2001 10:53:39 PM EST> <Error> <ConnectionManager> <Closing:
    'weblogic.r
    jvm.t3.T3JVMConnection@91cee' because of: 'Client received a routed
    message from
    an unknown JVM: '-5623439693736234706C:24.185.83.208''>
    I have taken the Stock Applet example from WL5.1 and it also exhibits
    the same problems. Since there are no examples with RMI and JNDI in
    WL6 maybe I am missing something. I create an initial an IntialContext
    and I can list and see any objects. But I will always wind up getting
    these errors that Peer has shutdown because a message has been
    received from an unknown VM. I have dumped out the info of and the
    message is coming from a "known" VM but the weblogic rmi subsystem
    seems to have lost the information. Any ideas or help would be
    grateful.
    Thanks
    Alex Jeannopoulos

    I have been working on converting an existing RMI Service- Client
    Application to use Weblogic 6.0. All the rmi services run in an
    external VM seperate from the WL server. This setup works fine with
    plain RMI, I have converted this to WL and JNDI. I get the following
    error after a few connections to the service have been made. It always
    happens.
    <Feb 18, 2001 10:53:39 PM EST> <Error> <ConnectionManager> <Closing:
    'weblogic.r
    jvm.t3.T3JVMConnection@91cee' because of: 'Client received a routed
    message from
    an unknown JVM: '-5623439693736234706C:24.185.83.208''>
    I have taken the Stock Applet example from WL5.1 and it also exhibits
    the same problems. Since there are no examples with RMI and JNDI in
    WL6 maybe I am missing something. I create an initial an IntialContext
    and I can list and see any objects. But I will always wind up getting
    these errors that Peer has shutdown because a message has been
    received from an unknown VM. I have dumped out the info of and the
    message is coming from a "known" VM but the weblogic rmi subsystem
    seems to have lost the information. Any ideas or help would be
    grateful.
    Thanks
    Alex Jeannopoulos

  • A rmi problem about exporting a remote object

    here is the code:
    public interface Hello extends Remote {
    String sayHello() throws RemoteException;
    public class HelloImpl extends UnicastRemoteObject
    implements Hello {
    public HelloImpl() throws RemoteException {
    super();
    public String sayHello() {
    return "Hello World!";
    public static void main(String args[]) {
    if (System.getSecurityManager() == null) {
         System.setSecurityManager(new RMISecurityManager());
    try{
         HelloImpl obj = new HelloImpl();
         Naming.rebind("//192.168.10.2:2001/HelloServer", obj);
         System.out.println("HelloServer bound in registry");
    }catch (Exception e) {
         System.out.println("HelloImpl err: " + e.getMessage());
    e.printStackTrace();
    public class HelloClient{
    public static void main(String[] args){
    Hello obj = null;
    String message="nobody say hello to me";
    if (System.getSecurityManager() == null) {
         System.setSecurityManager(new RMISecurityManager());
    try {
         obj = (Hello)Naming.lookup("//192.168.10.2:2001/HelloServer");
         message = obj.sayHello();
    }catch (Exception e) {
         System.out.println("exception: "+e.getMessage());
         e.printStackTrace();
    System.out.println(message);
    where 192.168.10.2 is the ip address of my computer.
    i'm using an mini-http server provided by sun,that is,ClassFileServer
    here is my command lines:
    java examples.classServer.ClassFileServer 2003 d:\java\rmi
    start rmiregistry 2001
    java -Djava.rmi.server.codebase=http://192.168.10.2:2001/
    -Djava.security.policy=server.policy HelloImpl
    then encountered the exception.
    can someone tell me how can i export the HelloImpl and
    make it can be invoked by client.
    thanks a lot!

    thank you for your reply,i tried it again like below:
    java examples.classServer.ClassFileServer 2001 d:\java\rmi
    start rmiregistry
    java -Djava.rmi.server.codebase=http://192.168.10.2:2001/
    -Djava.security.policy=server.policy HelloImpl
    java HelloClient
    but could not work,the exception raised at the client point is like that:
    java.rmi.Naming.lookup(unknown source)....
    i want to know how could the client know how to contact with
    rmiregistry,where the client trying to lookup(//192.168.10.2:2001/HelloServer)
    while rmiregistry running on the port 1099.
    thank you!

  • Rmi problem... with blobs

    i have to save some files on a remove server database
    and i am using rmi for this.
    i am able to pass the file name as parameter to the remote method but when i pass the file as the file object
    it not storing the file but only the detail so when i am using the fileinputstream to pass it to setbinarystream to set it the prepare statement it is not posible as the actual file is in the
    client and the setting or reading to the fileinputstream to set it for the setbinarysteam is done on the server.
    and there is an error that the file is not found ..
    any help or suggestion would be great
    thank you
    gautam

    You can't pass a File object as a parameter.

  • RMI problem with weblogic.jar

    We have a pure Java client that connects to the Weblogic server.
    While trying to connect we receive the error message below.
    I have unjarred the weblogic.jar file and discovered that the
    Stub.class is actually in weblogic/rmi/extensions/server/
    while it expects it to be in weblogic/rmi/extensions .
    Is there a fix for this as we are trying to upgrade from a previous version of weblogic and go live in Jan.
    Thanks
    Dave F
    java.lang.NoClassDefFoundError: weblogic/rmi/extensions/Stub(

    I'd suggest that you run the vm with the debug flag (-verbose) and see where the classes are being loaded; and examine the classpath to determine where the old jar or classes are occurring.
    Rita wrote:
    We have re-jarred the Stub.class and put it under weblogic/rmi/extensions, but when the java app runs, it still tries to look in weblogic/rmi/extensions/server. So, I think somewhere in the weblogic.jar, the path specified is still weblogic/rmi/extensions. Do you know what need to be done?
    Thanks,
    Rita
    Eduardo Ceballos <[email protected]> wrote:
    Yes, please regenerate your stub classes. That is, re-run rmic or ejbc.
    David Furlong wrote:
    We have a pure Java client that connects to the Weblogic server.
    While trying to connect we receive the error message below.
    I have unjarred the weblogic.jar file and discovered that the
    Stub.class is actually in weblogic/rmi/extensions/server/
    while it expects it to be in weblogic/rmi/extensions .
    Is there a fix for this as we are trying to upgrade from a previous version of weblogic and go live in Jan.
    Thanks
    Dave F
    java.lang.NoClassDefFoundError: weblogic/rmi/extensions/Stub(

  • RMI problem with j2sdk1.4

    Hi,
    I have written a simple Ping program, to exercise me with RMI, this program worked fine with jdk1.3, now I have downloaded j2sdk1.4 and I have installed it, I runned the RMI program but now I have a run-time error message.
    Could you explain me what can be happened?
    Thanks a lot

    The error message + stacktrace would help...
    did you also compile with jdk1.4 or just execute with the jre shipped with 1.4?

  • Rmi problem after java1.4 to java1.5 migration

    I have recently migrated one of my application module ( running on linux server )
    from jre1.4 to jre1.5_015
    Now my rmid server is at java1.5 and rmi client at java1.4 ...
    when i am trying to establish rmi connections from a single client i am able
    to cater to around 25 requests per second .. But the moment i start sending requests
    from another client simultaneously there's a drop in request rates that are being
    supported..
    What i have noticed is that there are TCP connections in CLOSE_WAIT state..
    and there is an increase in such connections as and when more packets are sent ...
    i got the info. about TCP connections in CLOSE_WAIT via command..
    netstat -an | grep 1098
    where 1098 is the port where rmi registry is running...
    I would like to know if there are some changes in java rmi which is causing these connections
    to take a longer time to establish and hence make my tcp connections go in CLOSE_WAIT state..

    Disable your firewall/security software adn try again.

Maybe you are looking for

  • Difference of sql query in SQL Workshop and SQL Report (case when sum(...

    Hi , I need some help, pls. The follwg report runs in SQL Workshop - but gives errors in the sql-query report in HTMLDB: SQL-Workshop: select case when SUM(S.POTENTIAL_GROWTH)> 1 and SUM(S.POTENTIAL_GROWTH) < 4 then 'Ok' when SUM(S.POTENTIAL_GROWTH)>

  • Extension Manager CS5 will not open in Windows XP

    I have been trying to install any extension in the EM CS5 and it will not open. I have removed it and re-installed several times with no luck. Is there an update or something I need to do to make this work? It will not run through Dreamweaver as well

  • Tried to connect to TV, display died

    I hope someone can help me with this one! I have been having some issues lately connecting my ibook to a tv ... kinda of had to fidget with the video plug to get it to work right. It would be almost all the way plugged in but not quite and then it wo

  • Cross company production cost

    Hello All, My question is: When I post a goods movement(cross plants belong to different company), i want to change the value at the FI document: case: Plant A,  company code A, Material  M01, standard price = 10 usd/pc Plant B,  company code B, Mate

  • Navigation issues with question slides in Captivate 6

    In earlier versions of Captivate (5.5) we have always been able to insert question slides into our projects as checkpoints and allow the user to freely navigate through the project and answer the checkpoint questions as often as they like. We have al