Port forwarding problems
843793Oct 29 2009 — edited Oct 30 2009Hi,
I'd really appreciate some help with the following. I have several java applets that each use an RMI server. This has been working find in a configuration where the server's DNS name is bound to its static IP address. Now, however, I am trying to use a configuration where the server's DNS name is bound to the static IP address of a cable modem, which is connected to a router, to which the server is attached. That is, flemingdp.com is bound to the static IP address 98.103.241.186, while the server has the static IP address 192.168.0.4. The router port forwards the rmiregistry port (1099) and the listening ports for the rmi servers (10099, etc) from 98.103.241.186 to 192.168.0.4. It also port forwards port 80, for example, and apache works. But rmi does not.
In one server, for example, I do
java.rmi.Naming.rebind("rmi://flemingdp.com/com.edermpath.dermpath_client.DataAccess);
where DataAccess extends UnicastRemoteObject and has this as the first line in its constructor:
super(10099,new MyClientSocketFactory(),new MyServerSocketFactory());
I have tried various settings for java.rmi.server.hostname when I start the server, without avail, and have also tried various settings in /etc/hosts.
Thanks in advance for your help -- this is really driving me nuts.
Matthew Fleming