I was trying to run selenium on Jenkins with Mocha framework using wdio. So following are the steps to solve this issue:-
Install google chrome
sudo apt-get update sudo apt-get install google-chrome-stable
Install chrome-driver
wget http://chromedriver.storage.googleapis.com/2.23/chromedriver_linux64.zipunzip chromedriver_linux64.zip
Run following commands to start selenium web server
nohup sudo Xvfb :10 -acexport DISPLAY=:10java -jar vendor/se/selenium-server-standalone/bin/selenium-server-standalone.jar -Dwebdriver.chrome.bin="/usr/bin/google-chrome" -Dwebdriver.chrome.driver="vendor/bin/chromedriver"
After this start you tests with wdio command
wdio wdio.conf.js