在 Windows Server 2019 上安装 Google Chrome(谷歌浏览器) 是完全可行的,尽管它不是默认安装的浏览器。以下是详细的安装步骤:
✅ 方法一:通过官方安装程序安装(推荐)
步骤 1:打开服务器上的浏览器(如 Microsoft Edge)
Windows Server 2019 自带 Microsoft Edge(旧版基于 EdgeHTML) 或 IE11,你可以使用它来下载 Chrome。
注意:如果你的服务器没有图形界面(如 Server Core 版本),请使用命令行或 PowerShell 安装(见方法三)。
步骤 2:访问 Google Chrome 官方网站
在浏览器中访问:
https://www.google.com/chrome/
步骤 3:下载 Chrome 安装程序
点击“下载 Chrome”按钮,选择“为所有用户安装”或“仅为你安装”,通常推荐选择“为所有用户安装”。
注意:会下载一个名为
ChromeSetup.exe的小型安装程序。
步骤 4:运行安装程序
- 打开下载的
ChromeSetup.exe。 - 按照提示完成安装。
- 安装完成后,Chrome 会自动启动。
✅ 方法二:使用 PowerShell 或 CMD 命令行静默安装(适合批量部署)
1. 下载 Chrome 离线安装包(适用于64位系统):
打开 PowerShell(以管理员身份运行),执行以下命令:
# 创建临时目录
New-Item -Path "$env:TEMPchrome" -ItemType Directory -Force
# 下载 Chrome 安装程序
Invoke-WebRequest -Uri "https://dl.google.com/chrome/install/latest/chrome_installer.exe" -OutFile "$env:TEMPchromechrome_installer.exe"
2. 静默安装(无需用户交互)
Start-Process -FilePath "$env:TEMPchromechrome_installer.exe" -ArgumentList "/silent /install" -Wait
安装完成后,Chrome 会出现在“开始菜单”中,所有用户都可以使用。
✅ 方法三:使用 Chocolatey 包管理器安装(推荐用于自动化)
如果你经常管理服务器,推荐安装 Chocolatey(Windows 的包管理器)。
1. 安装 Chocolatey(以管理员身份运行 PowerShell)
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
2. 安装 Google Chrome
choco install googlechrome -y
⚠️ 注意事项
-
安全警告:Windows Server 默认禁用 IE 增强安全配置(IE ESC),但 Chrome 不受此限制。建议在安装后关闭 IE ESC(可选):
- 打开 服务器管理器 → 本地服务器 → 点击 IE 增强的安全配置 → 设置为“关闭”。
-
更新机制:Chrome 安装后会自动通过后台服务(Google Update)更新,无需手动干预。
-
权限问题:建议以管理员身份运行安装程序,确保所有用户都能使用。
-
Server Core 用户注意:Windows Server Core 没有图形界面,无法运行 Chrome。Chrome 只支持带桌面体验的完整版 Windows Server。
✅ 验证安装
安装完成后:
- 在“开始菜单”中搜索 “Google Chrome”
- 或在运行窗口(Win+R)输入:
chrome.exe
总结
| 方法 | 适用场景 |
|---|---|
| 图形界面下载安装 | 单台服务器,有桌面环境 |
| PowerShell 静默安装 | 批量部署、脚本自动化 |
| Chocolatey 安装 | 高级用户,统一管理软件 |
如有需要,我也可以提供 批处理脚本(.bat) 或 PowerShell 脚本 一键安装 Chrome。
是否需要?
秒懂云