Raman: IN our network we have two clients , one from 10.10.10.x and other from 20.20.20.x . The server has one internal ipaddress 192.168.2.2 and two additional NIC cards , one is 10.10.10.1 and the other 20.20.20.1, in this way the two client cannot communicate with each other and RMI should be enabled on all the three ipaddress, ie client from 10.10.10.x should communicate with server thru 10.10.10.1 and client from 20.20.20.x should communicate with server thru 20.20.20.1
Can't you have a single interface for the RMI stub? Why is it required that the client from 10.10.10.x should have a different IP address in the RMI stub too.
I think there are two things:
Interface at which the rmi registry is running.Interface at which the client stub is connecting. If by saying "rmi is enabled" means the registry is available then you would have to have a routing rule i guess that will route all traffic from one interface on the registry port to another or a common interface to which the data is routed to from both 10.10.10.x and 20.20.20.x.
(I must say that I am not a networking expert but this is what i can think of)
If you are saying the client stub must contain different interfaces according to the interface on which it is invoked, then this is difficult if not impossible.
What is it that you loose if your client stub always connects on one IP address and registry is available on both?
I am sure nobody cares what interface the client stub is connecting too as long as the interface is a publicly available IP.
[ December 04, 2008: Message edited by: Nitesh Kant ]