1

I am trying to start chrome driver in Linux 3.10.0-327.36.3.el7 using selenium with python. Also got some useful help from the chrome documentation, my extract code snippet is

chromedriver = "/path/to/bin/chromedriver"
os.environ["webdriver.chrome.driver"] = chromedriver
driver = webdriver.Chrome(chromedriver,
              service_log_path = service_log_path, service_args=service_args)

But I am getting the error message below,

Message: unknown error: Chrome failed to start: exited abnormally (Driver info: chromedriver=2.29.461571 (8a88bbe0775e2a23afda0ceaf2ef7ee74e822cc5),platform=Linux 3.10.0-327.36.3.el7

I dont see a problem in the code (as far as I know), please help me with some fix.

Ahsanul Haque
  • 10,676
  • 4
  • 41
  • 57
Swami vijay
  • 11
  • 1
  • 2
  • Possible duplicate of [Selenium 'Chrome failed to start: exited abnormally' error](https://stackoverflow.com/questions/47596402/selenium-chrome-failed-to-start-exited-abnormally-error) – kerbalman Jan 24 '19 at 09:25

1 Answers1

-2

Not sure if you made your chromedriver executable ( on a Ubuntu/Linux/Mac system). If you didn't do that, your chromedriver wouldn't work.

Please try this - if you haven't

 chmod +x chromedriver

 chmod 777 chromedriver

And then try again. I wrote a simple script for this and I was able to get my chrome started perfectly -

import os
from selenium import webdriver

chrome_path="/home/rahul/Documents/SeleniumPy/chromedriver" //this is my chromedriver path

driver=webdriver.Chrome(chrome_path)

driver.maximize_window()

driver.implicitly_wait(30)
driver.get('http://www.google.com')

driver.quit()
demouser123
  • 4,108
  • 9
  • 50
  • 82
  • Thanks for the reply. My permissions with chromedriver is fine '-rwxr-xr-x' - it has execution permissions for all users. Just now tried your snippet and still the same error. – Swami vijay Apr 11 '17 at 19:42
  • 1
    Never chmod 777 anything! –  Jun 09 '17 at 08:45