Linux系统(Centos和Ubuntu)基本上默认都安装Firefox浏览器,但Chrome浏览器也是最爱啊,Ubuntu的安装比较方便,可Centos即便是到官网上下载了安装包还是有大概率装不上。采用yum工具安装虽然不太复杂,但还有些代码的,索性记录一下自己的安装过程,方便以后查找。

一、安装Google YUM源

打开终端,以管理员权限新建文件

# sudo vi /etc/yum.repos.d/google-chrome.repo

进入编辑页面后,输入如下代码

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

二、安装Chrome浏览器

首先,使用下述代码测试一下Google的源中是否有可用的最终版本

# yum info google-chrome-stable

输出如下:

Loading mirror speeds from cached hostfile
 * base: centos.ustc.edu.cn
 * epel: ftp.yz.yamagata-u.ac.jp
 * extras: centos.ustc.edu.cn
 * updates: centos.ustc.edu.cn
可安装的软件包
名称    :google-chrome-stable
架构    :x86_64
版本    :63.0.3239.132
发布    :1
大小    :47 M
源    :google-chrome/x86_64
简介    : Google Chrome
网址    :https://chrome.google.com/
协议    : Multiple, see https://chrome.google.com/
描述    : The web browser from Google
        : 
        : Google Chrome is a browser that combines a minimal design with
        : sophisticated technology to make the web faster, safer, and easier.

你能看到源中可用的版本是63.0.3239.132,基本上可以满足我们的要求。接下去就是通过yum命令自动安装。

# yum install google-chrome-stable

大约几分钟之后,安装结束。应用程序的菜单中就能看到Chrome的身影了。

最后修改:2018 年 01 月 07 日
如果觉得我的文章对你有用,请随意赞赏