Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Help on locate RMI registry in linux and window

 
lambertlee Li
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,

I just tested my application both in windows and linux machine.

I found a weired issue with my application(testing client running in remote mode):

(1)if I run my server in windows machine, client in linux machine. everything is fine. Client got connected, I could book/unbook etc.
(2)if I run my server in linux machine, client run in window machine, my client GUI couldn't connect to server, and I got the following exception:


"172.30.16.225" is my linux box IP.

My RMI registry look up I use this:


Just not understand why application only work fine one way. Window couldn't look up that registry in linux box. But linux box actually get locate the registry in window box. Does anyone ever encounter this problem?
 
Jeroen T Wenting
Ranch Hand
Posts: 1847
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Add logging in the server, see what that does.
You may have a problem in your serverside network configuration (outside your server or client code).
Many Linux machines for example have their hosts file set up to incorrectly define the loopback interface, causing the server to send back an incorrect ip address for the stub to the client, with the result that the stub can't talk to the server after being returned from it.
 
Mihai Radulescu
Ranch Hand
Posts: 918
IntelliJ IDE Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I encounter a similar problem, but in my case the linux machine has a firewall. A very restrictive one, I just switch it off and it works.

regards M
 
lambertlee Li
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Jeroen, It seems you are right. My linux box firewall was disabled. my client side sometimes catch exception like:



regardless I passed in my correct server IP address on
code:

But how can I fixed that network configuration on linux box? Do you have any idea where those host files sitting on in linux? Or maybe I could just ignore it as it seems it is the machine configuration problem as my codes works fine for the case of (client in linux, server in windows). Just scared that may lead to auto failure if accessor happen to encountered such an issue like this.
 
Jeroen T Wenting
Ranch Hand
Posts: 1847
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's most likely in /etc
If 127.0.0.1 is mapped to more than just localhost remove every other entry it had for that address.
I think that's enough, though you might have to remove the entire line for 127.0.0.1.
 
Sam Codean
Ranch Hand
Posts: 194
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i guess you are digging too much into the requirements. Not discouraging you from testing nice scenarios but then this multi platform testing is not necessary for the Test i believe.
 
Jeroen T Wenting
Ranch Hand
Posts: 1847
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's not about multiplatform testing but testing the scenario where the server runs on a different machine from the client.
You do want them to talk together in that scenario and in this case the machine on which the server runs is configured incorrectly.

Some people are here to learn something...
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic