• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

RMI Newbie needs help bad......

Eugene Armistead
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am starting to learn about RMI and I am running into a problem that I'm sure has a simple answer:
I am working on the examples in CORE JAVA, Volume II and on page 266-267 there is a simple example of an RMI Server. I typed in all of the code and it complies fine, but when I run it, I get an error that I can't connect to my localhost. I put a security policy file in (exactly like in the book) and started my server with the policy. I have TCP/IP running on Windows 2000 and everything is in the same directory. I am trying to start the registry on the default port. Here is how I am starting everything up (note that in the below example the IP is not my local host as I tried running this while connected to a dial-up network connection - I get the same results with the localhost IP if I am not on line and just have my NIC running):
E:\temp> dir
Volume in drive E has no label.
Volume Serial Number is C0A4-4886
Directory of E:\temp
10/24/2001 09:39p <DIR> .
10/24/2001 09:39p <DIR> ..
10/24/2001 09:01p 79 client.policy
10/24/2001 08:53p 219 Product.class
10/24/2001 08:53p 166 Product.java
10/24/2001 08:54p 630 ProductImpl.class
10/24/2001 08:52p 438 ProductImpl.java
10/24/2001 08:55p 1,434 ProductImpl_Skel.class
10/24/2001 08:55p 2,876 ProductImpl_Stub.class
10/24/2001 08:54p 1,098 ProductServer.class
10/24/2001 08:48p 777 ProductServer.java
9 File(s) 7,717 bytes
2 Dir(s) 7,615,070,208 bytes free
E:\temp> start rmiregistry
E:\temp> java ProductServer -Djava.security.policy=client.policy
Constructing server implementations...
Binding server implementations to registry...
***Error: java.rmi.ConnectException: Connection refused to host: 205.173
.118.189; nested exception is:
java.net.ConnectException: Connection refused: connect
What am I doing wrong???
Thanks for your help.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic