我有selenium独立服务器3.14.0,希望运行hub,然后在其上注册节点。我第一次运行中心就像
java -jar selenium-server-standalone-3.14.0.jar -role hub它工作得很好,并等待节点注册。然后运行这些命令来注册一个节点,
java -jar selenium-server-standalone-3.14.0.jar -role node -hub http://localhost:4444/register/grid -browser browserName=chrome,platform=WINDOWS但是它不断地给我这个错误,我不能注册任何节点。
11:30:47.634 INFO [SelfRegisteringRemote$1.run] - Couldn't register this node: The hub is down or not responding: Unexpected char 0x131 at 23 in User-Agent value: selenium/3.14.0 (java w²ndows)我该如何解决这个问题?
发布于 2018-10-02 09:26:43
这个错误信息..。
[SelfRegisteringRemote$1.run] - Couldn't register this node: The hub is down or not responding: Unexpected char 0x131 at 23 in User-Agent value: selenium/3.14.0 (java w²ndows)表示Selenium Grid节点没有注册到Selenium Grid中心的...implies。
您的主要问题是您的底层操作系统没有使用英语。
解决方案
在操作系统的英语版本中,尝试同样的方法,命令可以正常工作,不会有任何问题。
除此之外,我看不出你的命令有任何这样的问题。
启动Selenium Grid集线器的命令非常完善:
java -jar selenium-server-standalone-3.14.0.jar -role hub您应该看到以下启动日志:
C:\Utility\SeleniumGrid>java -jar selenium-server-standalone-3.14.0.jar -role hub
14:31:09.654 INFO [GridLauncherV3.launch] - Selenium build info: version: '3.14.0', revision: 'aacccce0'
14:31:09.659 INFO [GridLauncherV3$2.launch] - Launching Selenium Grid hub on port 4444
2018-10-02 14:31:10.381:INFO::main: Logging initialized @1570ms to org.seleniumhq.jetty9.util.log.StdErrLog
14:31:11.086 INFO [Hub.start] - Selenium Grid hub is up and running
14:31:11.087 INFO [Hub.start] - Nodes should register to http://192.168.1.5:4444/grid/register/
14:31:11.088 INFO [Hub.start] - Clients should connect to http://192.168.1.5:4444/wd/hub启动Selenium Grid节点的命令也很完美:
java -jar selenium-server-standalone-3.14.0.jar -role node -hub http://localhost:4444/register/grid -browser browserName=chrome,platform=WINDOWS您应该看到以下启动日志:
C:\Utility\SeleniumGrid>java -jar selenium-server-standalone-3.14.0.jar -role node -hub http://localhost:4444/register/grid -browser browserName=chrome,platform=WINDOWS
14:38:06.877 INFO [GridLauncherV3.launch] - Selenium build info: version: '3.14.0', revision: 'aacccce0'
14:38:06.904 INFO [GridLauncherV3$3.launch] - Launching a Selenium Grid node onport 27852
2018-10-02 14:38:07.459:INFO::main: Logging initialized @1105ms to org.seleniumhq.jetty9.util.log.StdErrLog
14:38:07.829 INFO [SeleniumServer.boot] - Selenium Server is up and running on port 27852
14:38:07.830 INFO [GridLauncherV3$3.launch] - Selenium Grid node is up and ready to register to the hub
14:38:08.069 INFO [SelfRegisteringRemote$1.run] - Starting auto registration thread. Will try to register every 5000 ms.
14:38:08.070 INFO [SelfRegisteringRemote.registerToHub] - Registering the node to the hub: http://localhost:4444/grid/register
14:38:09.108 INFO [SelfRegisteringRemote.registerToHub] - The node is registered to the hub and ready to use网格控制台位于http://localhost:4444/grid/console,如下所示:

https://stackoverflow.com/questions/52604761
复制相似问题