Linux怎么安装谷歌浏览器 Linux命令行安装Chrome教程【详解】
技术百科
冰火之心
发布时间:2026-01-27
浏览: 次 Linux下安装谷歌浏览器有五种命令行方法:一、APT仓库法(Ubuntu/Debian);二、DEB包直装法(离线/受限网络);三、Snap法(支持snapd的发行版);四、RPM法(CentOS/RHEL/Fedora);五、自动化脚本法(多发行版适配)。
如果您在Linux系统中需要通过命令行安装谷歌浏览器,但不确定该使用哪种方式或遇到依赖错误、源不可达等问题,则可能是由于发行版差异、架构识别错误或网络策略限制所致。以下是多种经验证的命令行安装方法:
一、通过APT仓库添加并安装(适用于Ubuntu/Debian系)
此方法将Google官方APT源加入系统软件源列表,确保后续可通过apt update自动获取安全更新与版本升级,适合长期使用且注重稳定性的用户。
1、下载Google Chrome的GPG签名密钥:wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | sudo gpg --dearmor -o /usr/share/keyrings/google-chrome-keyring.gpg
2、将Chrome稳定版仓库地址写入源配置文件:echo "deb [arch=amd64 signed-by=/usr/share/keyrings/google-chrome-keyring.gpg] https://dl.google.com/linux/chrome/deb/ stable main" | sudo tee /etc/apt/sources.list.d/google-chrome.list
3、更新本地APT包索引:sudo apt update
4、安装google-chrome-stable主程序包:sudo apt install google-chrome-stable -y
二、直接下载并安装DEB包(通用Debian系离线/受限网络场景)
当无法访问外部APT源或需跳过源配置步骤时,可直接获取官方构建的DEB安装包,由dpkg完成本地安装,操作轻量、路径可控。
1、使用wget获取最新稳定版64位DEB包:wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
2、调用dpkg执行安装:sudo dpkg -i google-chrome-stable_current_amd64. 
3、若提示依赖缺失,立即修复并重装:sudo apt --fix-broken install -y
三、使用Snap安装(适用于支持snapd的现代发行版)
Snaps是容器化软件包格式,自带运行时依赖,无需手动处理lib冲突,适合SELinux严格环境或Ubuntu Core等系统。
1、确认snapd服务已启用:sudo systemctl is-active snapd
2、如未运行则启动并设为开机自启:sudo systemctl enable --now snapd
3、从Snap Store安装稳定版Chrome:sudo snap install google-chrome
四、使用RPM包安装(适用于CentOS/RHEL/Fedora)
Red Hat系发行版原生支持RPM包管理,直接安装官方RPM可避免APT兼容性问题,且不依赖第三方仓库配置。
1、下载Chrome稳定版x86_64 RPM包:wget https://dl.google.com/linux/direct/google-chrome-stable_current_x86_64.rpm
2、使用dnf或yum进行本地安装:sudo dnf localinstall -y google-chrome-stable_current_x86_64.rpm
3、若使用较老版本RHEL/CentOS 7,改用yum命令:sudo yum localinstall -y google-chrome-stable_current_x86_64.rpm
五、执行自动化脚本安装(一键适配多发行版)
该方案通过社区维护的install_chrome.sh脚本自动探测系统类型、架构与包管理器,动态选择安装路径,降低人工判断成本。
1、下载脚本文件:wget http://chrome.richardlloyd.org.uk/install_chrome.sh
2、赋予脚本可执行权限:chmod u+x install_chrome.sh
3、以稳定版模式运行安装:sudo ./install_chrome.sh -s
# 自动化
# ai
# google
# 适用于
# 您在
# 离线
# 浏览器
# 设为
# 命令行
# 配置文件
# https
# linux
# centos
# ubuntu
# http
# debian
# go
# 主程序
# chrome
# amd
# 架构
# echo
# 软件包
# 发行版
# 稳定版
# dnf
# 谷歌
# 谷歌浏览器
# 多发
相关栏目:
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
AI推广<?muma echo $count; ?>
】
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
SEO优化<?muma echo $count; ?>
】
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
技术百科<?muma echo $count; ?>
】
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
谷歌推广<?muma echo $count; ?>
】
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
百度推广<?muma echo $count; ?>
】
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
网络营销<?muma echo $count; ?>
】
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
案例网站<?muma echo $count; ?>
】
<?muma
$count = M('archives')->where(['typeid'=>$field['id']])->count();
?>
【
精选文章<?muma echo $count; ?>
】
相关推荐
- Python装饰器复用技巧_通用能力解析【教程】
- 如何用正则与预处理高效拦截带干扰符的恶意域名
- Python代码测试策略_质量保障解析【教程】
- windows 10专注助手怎么关闭_window
- Win11怎样安装网易云音乐_Win11安装网易云
- Win11怎么关闭搜索历史 Win11清除搜索框最
- Mac如何将HEIC图片格式转为JPG_Mac批量
- C++如何解析JSON数据?(nlohmann/j
- Win11键盘快捷键大全_Windows 11常用
- Windows10如何更改盘符名称_Win10重命
- Win11怎么更改系统语言为中文_Windows1
- php后缀怎么变mp4能播放_让php伪装mp4正
- php嵌入式多设备通信怎么实现_php同时管理多个
- Windows10电脑怎么设置防火墙出站规则_Wi
- 企业SEO优化选择网站建设模板的技巧
- Mac如何彻底清理浏览器缓存?(Safari与Ch
- 如何在Golang中实现基础配置管理功能_Gola
- php下载安装包怎么选_threadsafe与nt
- c++如何利用doxygen生成开发文档_c++
- windows如何禁用驱动程序强制签名_windo
- Python数据挖掘核心算法实践_聚类分类与特征工
- 如何在Golang中实现文件下载_Golang文件
- 如何在 Go 中调用动态链接库(.so)中的函数
- Win11怎么设置DNS服务器_Windows11
- Win10如何优化内存使用_Win10内存优化技巧
- 如何诊断并终止卡死的 multiprocessin
- 使用类变量定义字符串常量时的类型安全最佳实践
- Windows10如何更改开机密码_Win10登录
- Win11怎么关闭粘滞键_彻底禁用Windows
- Mac如何解压zip和rar文件?(推荐免费工具)
- Win11怎么关闭键盘按键音_Win11禁用打字声
- Go 中 defer 在 goroutine 内部
- Mac如何修复应用程序权限问题_Mac磁盘工具修复
- VSC怎样在Linux运行PHP_Ubuntu系统
- 如何在 Python 中将 ISO 8601 时间
- 如何使用Golang实现Web表单数据绑定_自动映
- MAC怎么在照片中添加水印_MAC自带编辑工具文字
- Win11怎么退出微软账户_切换Win11为本地账
- Win11怎么关闭SmartScreen_禁用Wi
- Windows10系统怎么查看防火墙状态_Win1
- Win11怎么关闭透明效果_Windows11个性
- PHP接收参数值为空怎么办_判断和处理空参数方法说
- mac怎么分屏_MAC双屏显示与分屏操作技巧【指南
- 如何在Golang中使用encoding/gob序
- 如何在Golang中指定模块版本_使用go.mod
- PythonPandas数据分析项目教程_时间序列
- Win11笔记本怎么看电池健康度_Win11电池报
- Django 测试数据库表缺失与字段未创建问题的完
- Win11怎么关闭系统透明度_Windows11个
- php485在php5.6下能用吗_php485旧

QQ客服