Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I'm trying to run selenium server, and get errors:

rond-macpro:selenium eladb$  java -Dwebdriver.chrome.driver=./chromedriver -r selenium-server-standalone-2.44.0.jar
Unrecognized option: -r
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.

and without -r (what is it anyway?)

rond-macpro:selenium eladb$  java -Dwebdriver.chrome.driver=./chromedriver  selenium-server-standalone-2.44.0.jar
Error: Could not find or load main class selenium-server-standalone-2.44.0.jar

how should I start the server?

how do I set a non-default port to listen to?

These two posts: 1 2 - contradicts regarding the syntax. I think.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
323 views
Welcome To Ask or Share your Answers For Others

1 Answer

java -jar seleniumjar.jar -Dwebdriver.chrome.driver=./chromedriver 

If you want to specifiy the port do

java -jar seleniumjar.version.jar -Dwebdriver.chrome.driver=./chromedriver -port 4545

As of 3.8.1, specifying the driver is no longer necessary:

java -jar seleniumjar.jar

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...