简体   繁体   English

如何在RedHat Linux中安装ChromeDriver?

[英]How to install ChromeDriver in RedHat Linux?

I am trying to use selenium on RHEL(Red Hat). 我正在尝试在RHEL(Red Hat)上使用硒。

In order to use Chrome browser, I need to install the chromedriver. 为了使用Chrome浏览器,我需要安装chromedriver。

Does anyone know how to install this, or what command I need to use? 有谁知道如何安装它,或者我需要使用什么命令? I did not find any resources on this that worked. 我没有找到任何有效的资源。

Really appreciate any help. 真的感谢任何帮助。

Thank you. 谢谢。

I followed a process which worked for me. 我遵循了对我有用的过程。

I am using Redhat 7.4, and I've been through a lot to uninstall and install chrome and firefox, got partially successful with chrome and this is what I tried. 我正在使用Redhat 7.4,并且在卸载和安装chrome和firefox方面已经做了很多工作,并在chrome上取得了部分成功,这就是我尝试过的方法。

In the Linux terminal 在Linux终端中

Go to the root by typing 输入以下内容进入根目录

  • su - su-

Then type 然后输入

  • rpm -qa rpm -qa

then (ctrl+f) and search for the keywords "google" or " chrome" or "mozilla" or "firefox" to check whether they are present or not and if they are available, then uninstall( remove ) them by the following command ( if you want to remove them ) 然后(ctrl + f)并搜索关键字“ google”或“ chrome”或“ mozilla”或“ firefox”,以检查它们是否存在以及是否可用,然后通过以下命令卸载(删除)它们(如果要删除它们)

  • yum remove (theWholeName) 百胜删除(theWholeName)

this removes the application 这将删除应用程序

Then install chrome by the following process 然后通过以下过程安装chrome

type this in terminal 在终端输入

then a package gets downloaded in your home folder 然后将软件包下载到您的主文件夹中

Then type the following command - this installs the packages 然后键入以下命令-这将安装软件包

  • yum -y install (name of the downloaded folder with extension) yum -y install(带有扩展名的下载文件夹的名称)

in this case it will be 在这种情况下

  • yum -y install google-chrome-stable_current_x86_64.rpm yum -y安装google-chrome-stable_current_x86_64.rpm

This installs google chrome and creates an icon under Application->Internet->googleChrome 这将安装google chrome,并在Application-> Internet-> googleChrome下创建一个图标

IMPportant: IMPportant:

technically, by clicking this googlechrome icon- this should open the browser, but it doesn't open the browser for me, I dont know whats the problem and I appreciate any suggestion regarding this issue. 从技术上讲,单击此googlechrome图标-应该会打开浏览器,但不会为我打开浏览器,我不知道出了什么问题,并且感谢您对此问题的任何建议。

I open google chrome through terminal using this command 我使用此命令通过终端打开谷歌浏览器

  • google-chrome --no-sandbox 谷歌浏览器--no-sandbox

this opens the chrome browser. 这会打开Chrome浏览器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM