侧边栏壁纸
博主头像
落叶人生博主等级

走进秋风,寻找秋天的落叶

  • 累计撰写 130562 篇文章
  • 累计创建 28 个标签
  • 累计收到 9 条评论
标签搜索

目 录CONTENT

文章目录

CentOS 7环境下安装chrome浏览器

2023-12-08 星期五 / 0 评论 / 0 点赞 / 92 阅读 / 1362 字

1、修改yum源 在/etc/yum.repos.d/目录下新建文件google-chrome.repo,向其中添加如下内容: [google-chrome]name=google-chromebas

1、修改yum源

在/etc/yum.repos.d/目录下新建文件google-chrome.repo,向其中添加如下内容:

[google-chrome]name=google-chromebaseurl=http://dl.google.com/linux/chrome/rpm/stable/$basearchenabled=1gpgcheck=1gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub

2、安装

sudo yum install google-chrome-stable

注:Google官方源在国内可能无法正常访问,导致安装失败或安装后无法正常更新,可以尝试添加--nogpgcheck参数再安装。

sudo yum install google-chrome-stable --nogpgcheck

或者可以尝试修改gpgcheck=0再安装。

安装之后,如果你是root用户,启动会有类似提示

[root@localhostsoft]# [1:1:0402/171951:ERROR:nacl_fork_delegate_linux.cc(315)] Bad NaCl helper startup ack (0 bytes)

Chrome is not designed to run as root

. Running your browser as root is indeed a bad idea from security point of view, so you should do as @testdemoTestlast says and run it using regular user account. If for some reasons you need to run it as root 

 

这个问题在于它默认不能用 root 启动. 用以下启动方式,即解决了

google-chrome --no-sandbox --user-data-dir

广告 广告

评论区