Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

RMI ...  RSS feed

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I was trying to run the RMI Server, I got an error message like java.security.AccessControlException: access denied(java.net.socketpermission 127.0.0.1:1099 etc...). Could someone please help me out...
 
Ayman Jaffar
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sunil,
I had the same porblem, the reason for it to happen for me was becuase there was a misspell in my code for "policy.all" file, check your code again, even copy and paste it from the site if you want. I hope then it works !!
Tell me if you make the program run !!
[This message has been edited by Ayman Jaffar (edited November 16, 2000).]
 
Sean MacLean
author
Ranch Hand
Posts: 621
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can avoid messing with the JVM security policy if you put a custom policy in the same directory as your server and then run your server using the -D option. Here's an example of a simple policy file which I call "security.policy":

Put this in the same directory as your server and then start up you server like this:
java -Djava.rmi.server.hostname=myserver.com -Djava.security.policy=security.policy RMIServer &
Hope this helps
Sean
 
Rajendra Deshpande
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sunil,
Hope you did not forget to start the rmiregistry. Also check the port address if you are using something other than the default port.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!