Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Setup Selenium Server on Ubuntu 14.04
# Following the guide found at this page
echo "\r\nUpdating system ...\r\n"
sudo apt-get update
# Create folder to place selenium in
echo "\r\nCreating folder to place selenium in ...\r\n"
sudo mkdir ~/selenium
cd ~/selenium
# Get Selenium and install headless Java runtime
echo "\r\nInstalling Selenium and headless Java runtime ...\r\n"
sudo wget
sudo apt-get install openjdk-7-jre-headless -y
# Install Firefox
echo "\r\nInstalling Firefox ...\r\n"
sudo apt-get install firefox -y
# Install headless GUI for firefox. 'Xvfb is a display server that performs graphical operations in memory'
echo "\r\nInstalling XVFB (headless GUI for Firefox) ...\r\n"
sudo apt-get install xvfb -y
# Finally, starting up Selenium server
echo "\r\nStarting up Selenium server ...\r\n"
DISPLAY=:1 xvfb-run java -jar ~/selenium/selenium-server-standalone-2.44.0.jar
Copy link

ihadeed commented Mar 14, 2016

Thanks this is helpful

Copy link

hisachin commented May 21, 2016

Unable to access jarfile /home/sachin/selenium/selenium-server-standalone-2.44.0.jar

Copy link

mkinf commented May 25, 2016

@hisachin I think your problem comes from Java installation. Make sure you installed the new version of Java, add it in the path and put it in the same place as selenium driver.

Hope that this will help you.

Copy link

0xIslamTaha commented Jun 29, 2016

Please, Update this code with the latest versions :) and Thanks for your effort

Copy link

rutvij2292 commented Jul 13, 2016

Copy link

rutvij2292 commented Jul 13, 2016

Hi @curtismcmullan
Can you help me starting selenium server on startup? It would be a great help for many. Thanks for detailed commands for installing selenium.


Copy link

zxl777 commented Oct 24, 2016

How chrome worked headless ?

Copy link

maryamnik commented Mar 1, 2017

Thanks a lot, it really helped.

Copy link

JeroenSteen commented Jun 12, 2017

Is it also possible to run xvfb-run in the background? I tried DISPLAY=:1 xvfb-run java -jar ~/selenium/selenium-server-standalone-2.44.0.jar &.

Copy link

techkuz commented Aug 30, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment