• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

port of RMI

 
yi lu
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why only port 1099 do well in my computer?
when I use any other port number, an exception is throwed like this:java.rmi.ConnectException: Connection refused to host: localhost; nested exception is:java.net.ConnectException: Connection refused:java.lang.NullPointerException
is there any restriction with RMI'port? like closing firewall, start some system web server and so on.
my policy is :
grant {
permission java.security.AllPermission "", "";
permission java.net.SocketPermission "localhost:1024-65535","connect";
};
 
George Marinkovich
Ranch Hand
Posts: 619
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Yi,
You might find this thread might help to answer your question:
Topic: RMI Binding on localhost
I don't think the problem is the security manager and I believe that the use of the security manager is not required (in fact, in my assignment instructions it was explicitly prohibited). The problem may have to do with creating a registry using the new port, but then not using the newly created registry. Take a look at the above thread.
There's a tremendous amount of information on this forum, the search function is invaluable in sorting through it.
Hope this helps,
George
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic