close

[Solved] selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed

Hello Guys, How are you all? Hope You all Are Fine. Today I am just trying to use selenium webdriver but  the browser instance just doesn’t launch and give me following error selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed in python. So Here I am Explain to you all the possible solutions here.

Without wasting your time, Let’s start This Article to Solve This Error.

How selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed Error Occurs ?

I am just trying to use selenium webdriver but  the browser instance just doesn’t launch and give me following error.

selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed
  (unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /opt/google/chrome/google-chrome is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=2.43.600233, platform=Linux 4.15.0-38-generic x86_64)

How To Solve selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed Error ?

  1. How To Solve selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed Error ?

    To Solve selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed Error First of all check your chrome browser Version. Now just download chrome driver version that equal to your chrome version from here. Now just use following code.

  2. selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed

    To Solve selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: crashed Error First of all check your chrome browser Version. Now just download chrome driver version that equal to your chrome version from here. Now just use following code.

Solution 1: download chrome driver version that equal to your chrome version

First of all check your chrome browser Version. Now just download chrome driver version that equal to your chrome version from here. Now just use following code.

from selenium import webdriver
from selenium.webdriver.chrome.options import Options

chrome_options = Options()
chrome_options.add_argument('--headless')
chrome_options.add_argument('--no-sandbox')
chrome_options.add_argument('--disable-dev-shm-usage')
d = webdriver.Chrome('your-chrome-driver-path',chrome_options=chrome_options)
d.get('https://www.google.nl/')

Solution 2: Use this solution

from selenium import webdriver
from selenium.webdriver.chrome.options import Options

options = Options()
options.binary_location = "C:\\path\\to\\your\\chrome.exe"    #chrome binary location specified here
options.add_argument("--start-maximized") #open Browser in maximized mode
options.add_argument("--no-sandbox") #bypass OS security model
options.add_argument("--disable-dev-shm-usage") #overcome limited resource problems
options.add_experimental_option("excludeSwitches", ["enable-automation"])
options.add_experimental_option('useAutomationExtension', False)
driver = webdriver.Chrome(options=options, executable_path=r'C:\path\to\chromedriver.exe')
driver.get('http://google.com/')

Summary

It’s all About this issue. Hope all solution helped you a lot. Comment below Your thoughts and your queries. Also, Comment below which solution worked for you?

Also, Read

Leave a Comment