Selenium Grid Console shows "No route to host (Host unreachable)" even after the node is killed

281 views
Skip to first unread message

Prvn

unread,
Jul 19, 2018, 11:21:23 PM7/19/18
to Selenium Users
I created a custom proxy that extends `DefaultRemoteProxy`. I was able to successfully wire the proxy to the Hub. 

I ran a test which sent the request to the grid and this custom proxy spun up a local node instance in my another laptop and ran the test successfully. After the test is executed I put in a logic to terminate the node. Now if I go to grid/console it shows "Failed to connect" and then after 60 seconds this node disappears. This is very good.

Now I did the same thing using AWS EC2 instance. Hub is an EC2 instance and node is an EC2 instance. But after the test is done and the node is terminated... In grid/console it says "No route to host (Host unreachable)". And this node will never go away from grid/console.

Why is this happening?

Prvn

unread,
Jul 19, 2018, 11:39:41 PM7/19/18
to Selenium Users
More Details::

The only difference between spinning up a node in a local laptop and killing the node  ,, and spinning a node in EC2 instance is that..

The spun up node in the laptop is killed by "kill" command with the process ID of the java selelnium process. The local laptop is still running

However in the EC2 instance, I just destroy the node when I am done with my test

f r

unread,
Jul 31, 2019, 4:13:11 AM7/31/19
to Selenium Users
Hi Prvn,

We just face this problem, problem is 2 parts: (by the way we are using selenium grid 2 and our hub is linux, we have 2 type of nodes for chrome, 1 linux and 2 windows 2016 server )

1. In linux nodes, when we terminate the instance directly using boto 3, the java process is not able to closing gracefully, so it is not saying goodbye to hub. And hub will try to communicate during "timeout" parameter period. If you use lifecycle shut down for the node before terminating it, it is closing gracefully and saying goodbye to hub (you can see this log in hub "marking the node...." when you call lifecycle servlet shutdown) and hub is lefting this node after some node polling, another parameter group..

2. In windows nodes the same thing is happening. But we are facing a problem with the node shutdown via lifecycle servlet. When we do that we are not able to see any log in the hub. we are waiting "marking the node..." in the hub side. But we observe that the java process in windows node suddenly killed by the lifecycle servlet call and also we are getting http 200 from the node when we call shutdown end point. So we thought that possible problems in windows side can be:

a) It can not be related with security groups settings. Because linux ones are also using same security groups and using same hub.
b) It can be related a firewall rule in windows that is denying to go hub. But it is connecting to hub using again 4444 and it is running while testing. We are not observing any problem while test execution..
c) ...

We didn't find a way to solve the problem in windows nodes.. Any help would be appreciated.
 

20 Temmuz 2018 Cuma 06:39:41 UTC+3 tarihinde Prvn yazdı:
Reply all
Reply to author
Forward
0 new messages