Home >Java >javaTutorial >Why Do I Get \'java.rmi.ServerException: RemoteException Occurred in Server Thread (ClassNotFoundException)\' in My RMI Server?
"java.rmi.ServerException: RemoteException Occurred in Server Thread (ClassNotFoundException)"
Problem:
When attempting to start an RMI server, the following exception is encountered:
java.rmi.ServerException: RemoteException occurred in server thread; nested exception is: java.rmi.UnmarshalException: error unmarshalling arguments; nested exception is: java.lang.ClassNotFoundException: Interfaces.RemoteMethodIntf
Diagnosis:
The underlying issue is that the RMI Registry cannot find the class referenced in the remote interface. This can occur in several situations:
Solution:
In this particular case, the problem pertains to the Registry missing the necessary classes on its classpath. To resolve this issue, there are several options:
The above is the detailed content of Why Do I Get \'java.rmi.ServerException: RemoteException Occurred in Server Thread (ClassNotFoundException)\' in My RMI Server?. For more information, please follow other related articles on the PHP Chinese website!