Link to home
Start Free TrialLog in
Avatar of rnicholus
rnicholus

asked on

Rmi Client - Connection refused to host: xx.xx.xxx.xx

I have 2 rmi servers that are running on 2 different machines (A and C).

The Client for these servers runs on the 3rd machine (B).

All machines have linux OS.

Machine A and B do not have a firewall between each other.  

But there is a firewall between the A and C, also there is  a firewall between B and C.


                                 Firewall    
                                      ^  
Machine A                       |          Machine C
(rmi server 1)                 |         (rmi server 2)
                                      |
                                      |
Machine B                      |
(rmi client for 1 and 2)   |


The Rmi client on machine B is successful in looking up the rmi server 1's remote interface in rmi registry on machine a which runs on port 2001 and calling the methods on it.

But, for the Machine C

1.) It takes 15-20 secs to look up the rmi object for the rmi server 2's remote interface from the rmi registry that runs on the port 2001.
2.) It gets "Connection refused to host xx.x.xxx.xx, connection timed out when calling a method on the remote object"


I am guessing it might be some permission issue. But do not know where to start. Could anyone guide me.

Any help is very much appreciated.

Thank you.





ASKER CERTIFIED SOLUTION
Avatar of CEHJ
CEHJ
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of rnicholus
rnicholus

ASKER

Yesterday we checked the logs and and checked the traffic was being blocked

As Machine A and Machine C are inside our host company's firewall so disabling another firewall between C and B can work.

For the second option Triguna:

I have never written a proxy before. So I would like to try this option as well

Machine B and C have their own firewall and then there is a router firewall between these two

Does that mean the proxy needs to be written on both the machines?

Also could you give an example how would we lookup the rmi server's remote object  using proxy