请访问原文链接:如何禁用 Microsoft Edge 自动更新 (macOS, Windows),查看最新版。转载请保留出处。
作者:gc(at)sysin.org,主页:www.sysin.org
如何禁用 Mozilla Firefox 自动更新 如何禁用 Microsoft Edge 自动更新 如何禁用 Google Chrome 自动更新
未经用户允许自动更新,也不提供选项禁用自动更新,属实不文明不举,以下方法可以禁用自动更新。
Microsoft Edge for Windows
Microsoft Edge 如何自动更新?
当前以 Edge 88.0 版本为例,新版本将来可能有所变更:
企业版使用以下方法进行自动更新
服务:Microsoft Edge 更新 服务 (edgeupdate)Microsoft Edge 更新 服务 (edgeupdatem)Microsoft Edge Elevation Service (MicrosoftEdgeElevationService)任务计划:MicrosoftEdgeUpdateBrowserReplacementTaskMicrosoftEdgeUpdateTaskMachineCoreMicrosoftEdgeUpdateTaskMachineUA安装路径:C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe更新程序路径:C:\Program Files (x86)\Microsoft\EdgeUpdate\MicrosoftEdgeUpdate.exe
巨硬阿三不讲究,无论 64-bit 还是 32-bit 的 Edge 都安装在 “Program Files (x86”) 目录下面(Chrome 没有这个问题)。
用户版使用以下方法自动更新
任务计划:MicrosoftEdgeUpdateTaskUser当前用户的SIDCoreMicrosoftEdgeUpdateTaskUser当前用户的SIDUA例如:MicrosoftEdgeUpdateTaskUserS-1-5-21-3860493963-3742860931-3732056798-500CoreMicrosoftEdgeUpdateTaskUserS-1-5-21-3860493963-3742860931-3732056798-500UA用户版安装路径:C:\Users\用户名\AppData\Local\Microsoft\Edge\Application\msedge.exe自动更新程序路径:C:\Users\用户名\AppData\Local\Microsoft\EdgeUpdate\MicrosoftEdgeUpdate.exe
使用 PowerShell 禁用更新
if ([Environment]::Is64BitOperatingSystem -eq “True”) {#Write-Host "64-bit OS"$PF=${env:ProgramFiles(x86)}}else {#Write-Host "32-bit OS"$PF=$env:ProgramFiles}if ($(Test-Path "$PF\Microsoft\Edge\Application\msedge.exe") -eq "True") {# 结束进程taskkill /im MicrosoftEdgeUpdate.exe /ftaskkill /im msedge.exe /f# Microsoft Edge 更新服务#这里也可以使用 sc.exe stop "service name"Stop-Service -Name "edgeupdate"Stop-Service -Name "edgeupdatem"Stop-Service -Name "MicrosoftEdgeElevationService"# Windows 10 默认 PS 版本 5.1 没有 Remove-Service 命令# This cmdlet was added in PS v6. See https://docs.microsoft.com/en-us/powershell/scripting/whats-new/what-s-new-in-powershell-core-60?view=powershell-6#cmdlet-updates.#Remove-Service -Name "edgeupdate"#Remove-Service -Name "edgeupdatem"#Remove-Service -Name "MicrosoftEdgeElevationService"# sc 在 PowerShell 中是 Set-Content 别名,所以要使用 sc.exe 否则执行后无任何效果sc.exe delete "edgeupdate"sc.exe delete "edgeupdatem"sc.exe delete "MicrosoftEdgeElevationService"# 任务计划企业版schtasks.exe /Delete /TN \MicrosoftEdgeUpdateBrowserReplacementTask /Fschtasks.exe /Delete /TN \MicrosoftEdgeUpdateTaskMachineCore /Fschtasks.exe /Delete /TN \MicrosoftEdgeUpdateTaskMachineUA /F# 移除更新程序Remove-Item "$PF\Microsoft\EdgeUpdate" -Recurse -ForceWrite-Output "Disable Microsoft Edge Enterprise Auto Update Successful!"}elseif ($(Test-Path "$env:USERPROFILE\AppData\Local\Microsoft\Edge\Application\msedge.exe") -eq "True") {# 结束进程taskkill /im MicrosoftEdgeUpdate.exe /ftaskkill /im msedge.exe /f# 用户版没有创建服务# 获取SID方法function Get-CurrentUserSID {[CmdletBinding()]param()Add-Type -AssemblyName System.DirectoryServices.AccountManagementreturn ([System.DirectoryServices.AccountManagement.UserPrincipal]::Current).SID.Value}# 用户版任务计划schtasks.exe /Delete /TN \MicrosoftEdgeUpdateTaskUser$(Get-CurrentUserSID)Core /Fschtasks.exe /Delete /TN \MicrosoftEdgeUpdateTaskUser$(Get-CurrentUserSID)UA /F# 移除更新程序Remove-Item "$env:USERPROFILE\AppData\Local\Microsoft\EdgeUpdate" -Recurse -ForceWrite-Output "Disable Microsoft Edge Users Setup Auto Update Successful!"}else {Write-Output "No Microsoft Edge Installation Detected!"}
Microsoft Edge for Mac
在 macOS 中 Edge 使用 Microsoft AutoUpdate app 进行自动更新,只需要取消加载项和移除该 app 的执行权限(或者删除)即可。
launchctl unload /Library/LaunchAgents/com.microsoft.update.agent.plistsudo chmod -R 644 /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app# 或者直接删除更新程序sudo rm -rf /Library/Application\ Support/Microsoft/MAU2.0/
资源
Microsoft Edge 策略配置
Microsoft Edge 下载
- Windows
- Microsoft Edge X64.msi(固定链接,最新版)
- Microsoft Edge X86.msi(固定链接,最新版)
- macOS
- Microsoft Edge Universal (Apple Chip)(固定链接,最新版)
- Microsoft Edge 64-bit (Intel Chip)(固定链接,最新版)
