Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

RMI bind problems

 
Bryan Clauser
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I created a class that extends UnicastRemoteObject in a package called
package suncertify.db;
the file is located in the dir
/sun/suncertify/db/
I generate the stubs with the command:
rmic -classpath /sun/ -keep -d /sun/ suncertify.db.DataServer
The stub files show up in the /sun/suncertify/db
inside the DataServer class the constructor does the following:

I then set my PATH
export PATH=$PATH:/sun/
and run the following:
java -classpath /sun/ -Djava.security.policy="//sun/suncertify/db/policy" suncertify.db.DataServer
which returns me a
DataServer exception: RemoteException occurred in server thread; nested exception is:
java.rmi.UnmarshalException: error unmarshalling arguments; nested exception is:
java.lang.ClassNotFoundException: suncertify.db.DataServer_Stub

Any ideas?
 
Bryan Clauser
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
never mind, I think I was hitting my crack pipe to hard and forgot to set the codebase
running the following command worked:
D:\sun\suncertify\db>java -classpath d:\sun\ -Djava.rmi.server.codebase=file:///d:\sun\ -Djava.security.policy="d:\sun\suncertify\db\policy" suncertify.db.DataServer
don't pay attention to the OS changes, I bounce form NT at work to Linux at home, but the codebase was the problem.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic