1

I have set up selenium docker hub on my local host and it is up and running (however through Kitematic it shows 2 IP addresses for docker selenium-hub) (see this) enter image description here I have checked that docker selenium-hub is up and running fine on my local machine enter image description here

Main Problem start appearing when I try to register chrome-node from another machine

Now I want to run selenium docker chrome node on another machine so I fired following command on another machine (Node machine's IP Address is '192.168.80.135' & I want node-chrome docker to run on port '5555') . Command I fired for that is

docker run -d -p 5555:5555 -e REMOTE_HOST="http://192.168.80.135:5555" -e    
HUB_PORT_4444_TCP_ADDR="192.168.99.101" -e HUB_PORT_4444_TCP_PORT="4444" --  
name chrome-node selenium/node-chrome-debug:2.53.1

However firing above command shows this kinda errors in node-chrome-debug's console

06:10:03.690 INFO - I/O exception (java.net.NoRouteToHostException) caught     
when processing request to {}->http://192.168.99.101:4444: No route to host
06:10:03.690 INFO - Retrying request to {}->http://192.168.99.101:4444
08:25:15.809 INFO - Retrying request to {}->http://192.168.99.101:4444
08:25:18.809 INFO - I/O exception (java.net.NoRouteToHostException) caught     
when processing request to {}->http://192.168.99.101:4444: No route to host
08:25:18.809 INFO - Retrying request to {}->http://192.168.99.101:4444
08:25:21.809 INFO - Couldn't register this node: The hub is down or not     
responding: No route to host
08:25:29.809 INFO - I/O exception (java.net.NoRouteToHostException) caught     
when processing request to {}->http://192.168.99.101:4444: No route to host
08:25:29.810 INFO - Retrying request to {}->http://192.168.99.101:4444

Moreover I am not able to open selenium-hub url in node machine (http://192.168.99.101:4444/grid/console) is not working ..

Any kinda help would be appreciated .. Thanks in advance

Docker-Vm created in my local machine enter image description here

2
  • Your machines can't talk to each other. What's your networking topology? Commented Nov 14, 2016 at 22:35
  • So @johnharris85 we are trying out this docker stuff in our office, where in all machines are in same network . I have docker vm on my machine & have selenium hub image under docker vm . Now if i install selenium-chrome/ff-node in my docker vm , then it works . However when I try to make another machine (from my office network) as node , it is not able to connect to my docker vm (which is in my machine) . I doubt my docker vm (created under my local machine) is not able to see my office network . Moreover this is what network type of docker created vm is (attaching it in question) Commented Nov 15, 2016 at 4:16

1 Answer 1

1

I achieved above thing using this https://stackoverflow.com/a/36929518/3789189

Overall I did following things 1) Port forwarding as described above on 'default' vm of my local host computer A enter image description here

2) registering node from another computer (lets say 'Machine B') [Note : This command is fired in another machine B , It will create chrome-node docker container (staying under machine B's default vm) & register it to selenium-hub docker container (staying under 'default' vm of machine A) ]

    docker run -d -p 5555:5555 -p 5900:5900 -e 
    REMOTE_HOST="http://192.168.80.135:5555" -e 
    HUB_PORT_4444_TCP_ADDR="192.168.80.62" -e HUB_PORT_4444_TCP_PORT="4444" 
    --name chrome-node selenium/node-chrome-debug:2.53.1

3) port forwarding on 'default' vm of machine B also ... enter image description here

3rd step is the important one , if you don't do this then selenium hub will not be able to communicate with selenium-node docker image, which stays under machine B

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.