Gateway Issue

215 views
Skip to first unread message

Susanta a Adhikary

unread,
Dec 5, 2022, 2:22:19 AM12/5/22
to Selenium Users
Hi,

I have installed the selenium grid 4. But when I try to run the selenium code in my org k8s cluster I am getting th e below issue:

```
❯ kubectl logs selenium-chrome-node-fddc9dd8d-phdjl
2022-12-01 08:46:08,285 INFO Included extra file "/etc/supervisor/conf.d/selenium.conf" during parsing
2022-12-01 08:46:08,287 INFO RPC interface 'supervisor' initialized
2022-12-01 08:46:08,287 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2022-12-01 08:46:08,288 INFO supervisord started with pid 8
2022-12-01 08:46:09,289 INFO spawned: 'xvfb' with pid 10
2022-12-01 08:46:09,291 INFO spawned: 'vnc' with pid 11
2022-12-01 08:46:09,293 INFO spawned: 'novnc' with pid 12
2022-12-01 08:46:09,294 INFO spawned: 'selenium-node' with pid 13
2022-12-01 08:46:09,312 INFO success: selenium-node entered RUNNING state, process has stayed up for > than 0 seconds (startsecs)
Generating Selenium Config
Configuring server...
Setting up SE_NODE_HOST...
Setting up SE_NODE_PORT...
Setting up SE_NODE_GRID_URL...
Tracing is disabled
Selenium Grid Node configuration:
[events]
publish = "tcp://selenium-event-bus:4442"
subscribe = "tcp://selenium-event-bus:4443"

[node]
session-timeout = "300"
override-max-sessions = false
detect-drivers = false
drain-after-session-count = 0
max-sessions = 1

[[node.driver-configuration]]
display-name = "chrome"
stereotype = '{"browserName": "chrome", "browserVersion": "107.0", "platformName": "Linux"}'
max-sessions = 1

Starting Selenium Grid Node...
08:46:10.200 INFO [LoggingOptions.configureLogEncoding] - Using the system default encoding
08:46:10.207 INFO [OpenTelemetryTracer.createTracer] - Using OpenTelemetry for tracing
2022-12-01 08:46:10,294 INFO success: xvfb entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2022-12-01 08:46:10,295 INFO success: vnc entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2022-12-01 08:46:10,295 INFO success: novnc entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
08:46:10.441 INFO [UnboundZmqEventBus.<init>] - Connecting to tcp://selenium-event-bus:4442 and tcp://selenium-event-bus:4443
08:46:10.532 INFO [UnboundZmqEventBus.<init>] - Sockets created
08:46:11.534 INFO [UnboundZmqEventBus.<init>] - Event bus ready
08:46:11.636 INFO [NodeServer.createHandlers] - Reporting self as: http://192.168.169.58:5555
08:46:11.652 INFO [NodeOptions.getSessionFactories] - Detected 2 available processors
08:46:11.716 INFO [NodeOptions.report] - Adding chrome for {"browserVersion": "107.0","se:noVncPort": 7900,"browserName": "chrome","platformName": "LINUX","se:vncEnabled": true} 1 times
08:46:11.734 INFO [Node.<init>] - Binding additional locator mechanisms: relative, name, id
08:46:11.904 INFO [NodeServer$1.start] - Starting registration process for Node http://192.168.169.58:5555
08:46:11.905 INFO [NodeServer.execute] - Started Selenium node 4.6.0 (revision 79f1c02ae20): http://192.168.169.58:5555
08:46:11.913 INFO [NodeServer$1.lambda$start$1] - Sending registration event...
08:46:12.060 INFO [NodeServer.lambda$createHandlers$2] - Node has been added
Starting ChromeDriver 107.0.5304.62 (1eec40d3a5764881c92085aaee66d25075c159aa-refs/branch-heads/5304@{#942}) on port 8161
Only local connections are allowed.
Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.
[1669885294.420][SEVERE]: bind() failed: Cannot assign requested address (99)
ChromeDriver was started successfully.
09:01:35.043 INFO [LocalNode.newSession] - Session created by the Node. Id: 75291d0cdbcad7aa43f7604f0da310a3, Caps: Capabilities {acceptInsecureCerts: false, browserName: chrome, browserVersion: 107.0.5304.87, chrome: {chromedriverVersion: 107.0.5304.62 (1eec40d3a576..., userDataDir: /tmp/.com.google.Chrome.vpssif}, goog:chromeOptions: {debuggerAddress: localhost:38861}, networkConnectionEnabled: false, pageLoadStrategy: normal, platformName: LINUX, proxy: Proxy(), se:cdp: http://localhost:38861, se:cdpVersion: 107.0.5304.87, se:vncEnabled: true, se:vncLocalAddress: ws://192.168.169.58:7900, setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:credBlob: true, webauthn:extension:largeBlob: true, webauthn:virtualAuthenticators: true}
09:01:38.772 INFO [ProxyNodeWebsockets.createWsEndPoint] - Establishing connection to ws://192.168.169.58:7900
09:07:27.463 WARN [SpanWrappedHttpHandler.execute] - Unable to execute request: java.net.http.HttpTimeoutException: request timed out
Build info: version: '4.6.0', revision: '79f1c02ae20'
System info: os.name: 'Linux', os.arch: 'amd64', os.version: '5.4.0-29-generic', java.version: '11.0.16'
Driver info: driver.version: unknown
org.openqa.selenium.TimeoutException: java.net.http.HttpTimeoutException: request timed out
Build info: version: '4.6.0', revision: '79f1c02ae20'
System info: os.name: 'Linux', os.arch: 'amd64', os.version: '5.4.0-29-generic', java.version: '11.0.16'
Driver info: driver.version: unknown
        at org.openqa.selenium.remote.http.jdk.JdkHttpClient.execute(JdkHttpClient.java:282)
        at org.openqa.selenium.remote.tracing.TracedHttpClient.execute(TracedHttpClient.java:55)
        at org.openqa.selenium.grid.web.ReverseProxyHandler.execute(ReverseProxyHandler.java:92)
        at org.openqa.selenium.grid.node.ProtocolConvertingSession.execute(ProtocolConvertingSession.java:75)
        at org.openqa.selenium.grid.node.local.SessionSlot.execute(SessionSlot.java:127)
        at org.openqa.selenium.grid.node.local.LocalNode.executeWebDriverCommand(LocalNode.java:460)
        at org.openqa.selenium.grid.node.ForwardWebDriverCommand.execute(ForwardWebDriverCommand.java:35)
        at org.openqa.selenium.remote.http.Route$PredicatedRoute.handle(Route.java:373)
        at org.openqa.selenium.remote.http.Route.execute(Route.java:68)
        at org.openqa.selenium.remote.tracing.SpanWrappedHttpHandler.execute(SpanWrappedHttpHandler.java:86)
        at org.openqa.selenium.remote.http.Filter$1.execute(Filter.java:64)
        at org.openqa.selenium.remote.http.Route$CombinedRoute.handle(Route.java:336)
        at org.openqa.selenium.remote.http.Route.execute(Route.java:68)
        at org.openqa.selenium.grid.node.Node.execute(Node.java:240)
        at org.openqa.selenium.remote.http.Route$CombinedRoute.handle(Route.java:336)
        at org.openqa.selenium.remote.http.Route.execute(Route.java:68)
        at org.openqa.selenium.remote.AddWebDriverSpecHeaders.lambda$apply$0(AddWebDriverSpecHeaders.java:35)
        at org.openqa.selenium.remote.ErrorFilter.lambda$apply$0(ErrorFilter.java:44)
        at org.openqa.selenium.remote.http.Filter$1.execute(Filter.java:64)
        at org.openqa.selenium.remote.ErrorFilter.lambda$apply$0(ErrorFilter.java:44)
        at org.openqa.selenium.remote.http.Filter$1.execute(Filter.java:64)
        at org.openqa.selenium.netty.server.SeleniumHandler.lambda$channelRead0$0(SeleniumHandler.java:44)
        at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: java.net.http.HttpTimeoutException: request timed out
        at java.net.http/jdk.internal.net.http.HttpClientImpl.send(HttpClientImpl.java:559)
        at java.net.http/jdk.internal.net.http.HttpClientFacade.send(HttpClientFacade.java:119)
        at org.openqa.selenium.remote.http.jdk.JdkHttpClient.execute(JdkHttpClient.java:280)
        ... 26 more
```

But when I locally install it in my system, it works fine.

I am not able to understand the difference.

Regards,
Susanta


David Noakes

unread,
Feb 12, 2023, 9:35:40 PM2/12/23
to Selenium Users
We had a similar issue the other day where Chrome has been updated and the current server version no longer supported that version. 

check all these first as it did take us a little while to figure out why we were getting Driver info: driver.version: unknown 

Find us at:

      
Glasgow / London / Liverpool / Redditch / USA
https://us06web.zoom.us/webinar/register/6516729155569/WN_P-WUPr67SSKqmkwUax7e-Q
Elcom International, Inc. is a Delaware corporation registered in the U.S.A. with a Federal ID number of 04-3175156.  Elcom Systems Limited is registered in England and Wales with Company Number 02838561 and Elcom Funding Solutions is registered in England and Wales with Company Number 09349933.  Their registered office is at Orion House | 5 St Martin’s Lane | London | WC2H 9AE | UK

The contents of this e-mail and any attachments may be confidential and/or privileged and are intended for the named recipient only.  If it has come to you in error, you should not use, distribute or show any of its content to any other person without the express permission of the sender.  If you are not the intended recipient or responsible to deliver this email and any attachments to the intended recipient, please do not use or publish its contents.  Notify the sender by reply email and destroy all copies and attachments of the original message. Do not use or publish the contents or otherwise share in any manner.  Emails are not secure and may contain viruses. Elcom may monitor traffic data. Further information about us is available at www.elcom.com.

Jisha George

unread,
Feb 14, 2023, 1:35:36 AM2/14/23
to seleniu...@googlegroups.com
I am also facing similar issue of  gateway error but only when  trying parallel run on selenium grid on kubernates.

--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/b4ba1c46-fc8d-46a1-95af-cb98fcb57287n%40googlegroups.com.

Arnold84

unread,
Feb 17, 2023, 3:52:38 AM2/17/23
to Selenium Users
I have the same issue.
The tests run in parallel but I don"t use  kubernetes.
it is Selenium (grid) 4.8.0.
This issue is pretty rare in my case but makes the tests flaky.

Message: java.net.http.HttpTimeoutException: request timed out Build info: version: '4.8.0', revision: '267030adea' System info: os.name: 'Linux', os.arch: 'amd64', os.version: '4.19.0-23-amd64', java.version: '11.0.16' Driver info: org.openqa.selenium.remote.RemoteWebDriver Command: [480ea7edba4cab2294694f2175704c14, findElement {using=xpath, value=/html[1]/body[1]}] Capabilities {acceptInsecureCerts: false, browserName: chrome, browserVersion: 109.0.5414.119, chrome: {chromedriverVersion: 109.0.5414.74 (e7c5703604da..., userDataDir: /tmp/.com.google.Chrome.VLj98K}, goog:chromeOptions: {debuggerAddress: localhost:39441}, networkConnectionEnabled: false, pageLoadStrategy: normal, platformName: LINUX, proxy: Proxy(), se:bidiEnabled: false, se:cdp: ws://xxx:4444/sessio..., se:cdpVersion: xxx, se:vnc: ws://xxxx:4444/sessio..., se:vncEnabled: true, se:vncLocalAddress: ws://xxx:7900, setWindowRect: true, strictFileInteractability: false, timeouts: {implicit: 0, pageLoad: 300000, script: 30000}, unhandledPromptBehavior: dismiss and notify, webauthn:extension:credBlob: true, webauthn:extension:largeBlob: true, webauthn:virtualAuthenticators: true} Session ID: 480ea7edba4cab2294694f2175704c14

Stacktrace:
at org.openqa.selenium.remote.http.jdk.JdkHttpClient.execute(JdkHttpClient.java:294) at org.openqa.selenium.remote.tracing.TracedHttpClient.execute(TracedHttpClient.java:55) at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:181) at org.openqa.selenium.remote.TracedCommandExecutor.execute(TracedCommandExecutor.java:51) at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:543) at org.openqa.selenium.remote.ElementLocation$ElementFinder$2.findElement(ElementLocation.java:162) at org.openqa.selenium.remote.ElementLocation.findElement(ElementLocation.java:60) at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:352) at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:344) at com.vtech.gestion.fonctionnalites.communiquer.communicationsAdministrativesSV.DataGridCommunicationsAdministrativesSV.getCommunicationsAdministrativesById(DataGridCommunicationsAdministrativesSV.java:47) at com.vtech.tests.regression.communiquer.TestRegressionCommunicationsSV.RegressionCommunicationsSV_VisibiliteCommunicationsAdministratives(TestRegressionCommunicationsSV.java:70) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:566) at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:124) at org.testng.internal.Invoker.invokeMethod(Invoker.java:583) at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:719) at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:989) at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:125) at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109) at org.testng.TestRunner.privateRun(TestRunner.java:648) at org.testng.TestRunner.run(TestRunner.java:505) at org.testng.SuiteRunner.runTest(SuiteRunner.java:455) at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:450) at org.testng.SuiteRunner.privateRun(SuiteRunner.java:415) at org.testng.SuiteRunner.run(SuiteRunner.java:364) at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52) at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:84) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:829) Caused by: java.net.http.HttpTimeoutException: request timed out at java.net.http/jdk.internal.net.http.HttpClientImpl.send(HttpClientImpl.java:559) at java.net.http/jdk.internal.net.http.HttpClientFacade.send(HttpClientFacade.java:119) at org.openqa.selenium.remote.http.jdk.JdkHttpClient.execute(JdkHttpClient.java:292) ... 31 more

Maybe we should create an issue in the Selenium Github project but I don't know how to reproduce this exception.
Reply all
Reply to author
Forward
0 new messages