Announcement Announcement Module
Collapse
No announcement yet.
RMI on two different machines problem Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • RMI on two different machines problem

    Hi all,

    am trying to make and RMI connection using org.springframework.remoting.rmi.RmiServiceExporte r when I run the server and the client on the same machine it works fine but when I run the client on different machine I get the following exception

    Code:
    Caused by: java.lang.ClassNotFoundException: org.springframework.remoting.rmi.RmiInvocationWrapper_Stub (no security manager: RMI class loader disabled)
    	at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:375)
    	at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:165)
    	at java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:620)
    	at java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:247)
    	at sun.rmi.server.MarshalInputStream.resolveClass(MarshalInputStream.java:197)
    	at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1575)
    	at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1496)
    	at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1732)
    	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    	... 36 more
    The needed classes are on the client path!!
    any idea??

  • #2
    (no security manager: RMI class loader disabled)
    You need to add a security policy as the error message says.

    Specify the following options
    -Djava.security.manager -Djava.security.policy=security.policy

    Define your security policy (in a file security.policy) as follows
    grant {
    // Allow everything for now
    permission java.security.AllPermission;
    };

    Comment

    Working...
    X