“我们无法完成更新。正在撤消更改”无限循环

“我们无法完成更新。正在撤消更改”无限循环

我需要帮助,每次我启动/重新启动/关闭计算机时,它都会尝试安装 Windows 更新并失败,并显示以下内容:

在此处输入图片描述

我可以正常启动我的电脑并毫无问题地使用它经过漫长的等待...

我已经运行了以下操作:

dism /online /cleanup-image /startcomponentcleanup
dism /online /cleanup-image /scanhealth
dism /online /cleanup-image /restorehealth
dism /online /cleanup-image /restorehealth /source:E:\sources\install.wim
sfc /scannow

无数次,不用说,没有检测到损坏,一切都修复了——除了这个无休止的更新失败循环......

我想卸载这些更新,但它们尚未正确安装;

我打开了 appwiz.cpl\installed updates,发现了四个可能导致问题的更新:

在此处输入图片描述

只有 KB4580419 有“卸载”选项,其他三个都没有。

尝试了这些,没有观察到效果;

wusa /uninstall /kb:4594440 /quiet /norestart
wusa /uninstall /kb:4562830 /quiet /norestart
wusa /uninstall /kb:4593175 /quiet /norestart
wusa /uninstall /kb:4580419 /quiet /norestart

删除 /quiet 参数并尝试卸载一个更新,它打开了 Windows 更新独立安装程序,它运行并挂起,在 taskmgr 中它的状态为暂停,单击取消而没有效果,幸运的是我可以在 taskmgr 中杀死它;

我已经运行过这个:

dism /online /get-packages /format:table

发现很多状态为“安装待定”和“已暂存”的软件包

运行这个:

(Get-WindowsPackage -Online | Where {$_.PackageState -eq "Staged" -or $_.PackageState -eq "InstallPending"}).PackageName

结果:

Microsoft-OneCore-DeveloperMode-Desktop-Package~31bf3856ad364e35~amd64~~10.0.19041.662
Microsoft-OneCore-Graphics-Tools-Package~31bf3856ad364e35~amd64~~10.0.19041.488
Microsoft-WebDriver-Package~31bf3856ad364e35~amd64~~10.0.19041.610
Microsoft-Windows-Client-LanguagePack-Package~31bf3856ad364e35~amd64~en-US~10.0.19041.662
Microsoft-Windows-Client-LanguagePack-Package~31bf3856ad364e35~amd64~fr-FR~10.0.19041.662
Microsoft-Windows-Client-LanguagePack-Package~31bf3856ad364e35~amd64~zh-CN~10.0.19041.662
Microsoft-Windows-Hello-Face-Package~31bf3856ad364e35~amd64~~10.0.19041.662
Microsoft-Windows-LanguageFeatures-Handwriting-zh-cn-Package~31bf3856ad364e35~amd64~~10.0.19041.488
Microsoft-Windows-Media-Features-Package~31bf3856ad364e35~amd64~en-US~10.0.19041.488
Microsoft-Windows-Media-Features-Package~31bf3856ad364e35~amd64~fr-FR~10.0.19041.488
Microsoft-Windows-Media-Features-Package~31bf3856ad364e35~amd64~zh-CN~10.0.19041.488
Microsoft-Windows-Media-Features-Package~31bf3856ad364e35~amd64~~10.0.19041.685
Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~amd64~~10.0.19041.546
Microsoft-Windows-Notepad-FoD-Package~31bf3856ad364e35~amd64~fr-FR~10.0.19041.488
Microsoft-Windows-Notepad-FoD-Package~31bf3856ad364e35~amd64~zh-CN~10.0.19041.488
Microsoft-Windows-Printing-WFS-FoD-Package~31bf3856ad364e35~amd64~fr-FR~10.0.19041.488
Microsoft-Windows-Printing-WFS-FoD-Package~31bf3856ad364e35~amd64~zh-CN~10.0.19041.488
Microsoft-Windows-StorageManagement-FoD-Package~31bf3856ad364e35~amd64~en-US~10.0.19041.488
Microsoft-Windows-StorageManagement-FoD-Package~31bf3856ad364e35~amd64~fr-FR~10.0.19041.488
Microsoft-Windows-StorageManagement-FoD-Package~31bf3856ad364e35~amd64~zh-CN~10.0.19041.488
Microsoft-Windows-StorageManagement-FoD-Package~31bf3856ad364e35~amd64~~10.0.19041.662
Microsoft-Windows-UserExperience-Desktop-Package~31bf3856ad364e35~amd64~~10.0.19041.662
Microsoft-Windows-WordPad-FoD-Package~31bf3856ad364e35~amd64~~10.0.19041.662
Microsoft-Windows-Xps-Xps-Viewer-Opt-Package~31bf3856ad364e35~amd64~~10.0.19041.662
Package_for_DotNetRollup~31bf3856ad364e35~amd64~~10.0.4300.1
Package_for_KB4562830~31bf3856ad364e35~amd64~~10.0.1.3
Package_for_RollupFix~31bf3856ad364e35~amd64~~19041.685.1.6

然后我运行了这个:

(Get-WindowsPackage -Online | Where {$_.PackageState -eq "Staged" -or $_.PackageState -eq "InstallPending"}).PackageName | %{dism /Online /Remove-Package /PackageName:${_} /norestart}

在 C: 中找到 $SysReset、$WINDOWS.~BT、$WinREAgent、Recovery、“System Volume Information”文件夹,其内容为:

C:\$SysReset\CloudImage
C:\$SysReset\Logs
C:\$SysReset\MDM
C:\$SysReset\OldOS
C:\$SysReset\Scratch
C:\$SysReset\Logs\PushButtonReset.etl
C:\$SysReset\Logs\SessionID.xml
C:\$SysReset\Logs\setupact.log
C:\$SysReset\Logs\setuperr.log
C:\$SysReset\Logs\Timestamp.xml
C:\$WINDOWS.~BT\Sources
C:\$WINDOWS.~BT\Sources\Panther
C:\$WINDOWS.~BT\Sources\Panther\actionable.xsl
C:\$WINDOWS.~BT\Sources\Panther\AltData.cab
C:\$WINDOWS.~BT\Sources\Panther\appraiser.sdb
C:\$WINDOWS.~BT\Sources\Panther\Appraiser_Data.ini
C:\$WINDOWS.~BT\Sources\Panther\Appraiser_TelemetryRunList.xml
C:\$WINDOWS.~BT\Sources\Panther\CompatData_2020_12_18_13_43_45_3_00000021.xml
C:\$WINDOWS.~BT\Sources\Panther\CompatData_2020_12_18_13_43_48_3_00000021.xml
C:\$WINDOWS.~BT\Sources\Panther\compatscancache.dat
C:\$WINDOWS.~BT\Sources\Panther\DeviceBlock_Modern.xsl
C:\$WINDOWS.~BT\Sources\Panther\diagerr.xml
C:\$WINDOWS.~BT\Sources\Panther\diagwrn.xml
C:\$WINDOWS.~BT\Sources\Panther\Dissmissable_Modern.xsl
C:\$WINDOWS.~BT\Sources\Panther\Full.xsl
C:\$WINDOWS.~BT\Sources\Panther\full_connected.xsl
C:\$WINDOWS.~BT\Sources\Panther\IB85T7xeB0WQR8TH.4.4.0.0_APPRAISER_EverythingSys.bin
C:\$WINDOWS.~BT\Sources\Panther\IB85T7xeB0WQR8TH.4.4.0.0_APPRAISER_HumanReadable.xml
C:\$WINDOWS.~BT\Sources\Panther\IB85T7xeB0WQR8TH.4.4.0.0_APPRAISER_SetupOutput.xml
C:\$WINDOWS.~BT\Sources\Panther\IB85T7xeB0WQR8TH.4.4.0.0_APPRAISER_SetupOutputHw.xml
C:\$WINDOWS.~BT\Sources\Panther\ie6png.js
C:\$WINDOWS.~BT\Sources\Panther\img
C:\$WINDOWS.~BT\Sources\Panther\modern.xsl
C:\$WINDOWS.~BT\Sources\Panther\namedTemplates.xsl
C:\$WINDOWS.~BT\Sources\Panther\Overview.xsl
C:\$WINDOWS.~BT\Sources\Panther\Overview_connected.xsl
C:\$WINDOWS.~BT\Sources\Panther\PreDownload_AppUninstall.xsl
C:\$WINDOWS.~BT\Sources\Panther\Resources
C:\$WINDOWS.~BT\Sources\Panther\Save.xsl
C:\$WINDOWS.~BT\Sources\Panther\Save_connected.xsl
C:\$WINDOWS.~BT\Sources\Panther\ScanResult.xml
C:\$WINDOWS.~BT\Sources\Panther\setupact.log
C:\$WINDOWS.~BT\Sources\Panther\setuperr.log
C:\$WINDOWS.~BT\Sources\Panther\SetupReports.css
C:\$WINDOWS.~BT\Sources\Panther\setupReportsLoc.css
C:\$WINDOWS.~BT\Sources\Panther\setup_strings.xml
C:\$WINDOWS.~BT\Sources\Panther\SummaryInfo_Modern.xsl
C:\$WINDOWS.~BT\Sources\Panther\SummaryReport.html
C:\$WINDOWS.~BT\Sources\Panther\tables.js
C:\$WINDOWS.~BT\Sources\Panther\urls.xml
C:\$WINDOWS.~BT\Sources\Panther\wica_strings.xml
C:\$WINDOWS.~BT\Sources\Panther\windlp.state-old.xml
C:\$WINDOWS.~BT\Sources\Panther\windlp.state.xml
C:\$WINDOWS.~BT\Sources\Panther\img\defaultApp.png
C:\$WINDOWS.~BT\Sources\Panther\img\defaultPlugins.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_battery.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_biometric.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_bluetooth.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_cdrom.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_default.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_diskdrive.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_display.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_floppydisk.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_hidclass.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_image.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_keyboard.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_modem.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_monitor.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_mouse.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_mtd.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_net.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_pcmcia.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_printer.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_sensor.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_smartcardreader.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_tapedrive.png
C:\$WINDOWS.~BT\Sources\Panther\img\device_usb.png
C:\$WINDOWS.~BT\Sources\Panther\img\failure.png
C:\$WINDOWS.~BT\Sources\Panther\img\setupactiondefault.png
C:\$WINDOWS.~BT\Sources\Panther\img\warning.png
C:\$WINDOWS.~BT\Sources\Panther\img\wontwork.png
C:\$WINDOWS.~BT\Sources\Panther\img\works.png
C:\$WinREAgent\Scratch
C:\System Volume Information\EDP
C:\System Volume Information\IndexerVolumeGuid
C:\System Volume Information\Windows Backup
C:\System Volume Information\WindowsImageBackup
C:\System Volume Information\WPSettings.dat
C:\System Volume Information\Chkdsk\Chkdsk20201221110016.log
C:\System Volume Information\EDP\Recovery
C:\System Volume Information\Windows Backup\Catalogs
C:\System Volume Information\Windows Backup\Catalogs\GlobalCatalogLock.dat
C:\System Volume Information\WindowsImageBackup\SPPMetadataCache

C:\Windows\SoftwareDistribution:

Folder PATH listing for volume Windows
Volume serial number is 641B-479B
C:\WINDOWS\SOFTWAREDISTRIBUTION
├───DataStore
│   └───Logs
├───Download
│   ├───40c9e31f3fa1731b9f71da79d884fbe6
│   ├───ae6a47efe9fd0e03da033575571e7c6d
│   │   └───cbshandler
│   ├───baa66f28726f701d6508d16b26235240
│   │   ├───Metadata
│   │   │   └───Windows10.0-KB4593175-x64-EXPRESS
│   │   └───Package_for_KB4593175~~amd64~~19041.680.1.0
│   │       ├───amd64_microsoft-windows-s..-installers-onecore_31bf3856ad364e35_10.0.19041.680_none_c984780e045b899c
│   │       ├───amd64_microsoft-windows-s..cingstack-onecoreds_31bf3856ad364e35_10.0.19041.680_none_9220853e80a07cef
│   │       ├───amd64_microsoft-windows-s..ck-mof-onecoreadmin_31bf3856ad364e35_10.0.19041.680_none_f789f0d48e0af1d8
│   │       ├───amd64_microsoft-windows-s..formers-shell-extra_31bf3856ad364e35_10.0.19041.680_none_c7d6d41fdc1eaa2b
│   │       ├───amd64_microsoft-windows-s..gstack-boot-onecore_31bf3856ad364e35_10.0.19041.680_none_338f2b4bcf702713
│   │       ├───amd64_microsoft-windows-s..ingstack-base-extra_31bf3856ad364e35_10.0.19041.680_none_fcccf2982248b1b5
│   │       ├───amd64_microsoft-windows-s..k-transformers-core_31bf3856ad364e35_10.0.19041.680_none_49fba22634662d4d
│   │       ├───amd64_microsoft-windows-s..llers-onecore-extra_31bf3856ad364e35_10.0.19041.680_none_01a2caa8222e0a15
│   │       ├───amd64_microsoft-windows-s..ngstack-onecorebase_31bf3856ad364e35_10.0.19041.680_none_ce4cfd4440d93c2d
│   │       ├───amd64_microsoft-windows-s..ransformers-onecore_31bf3856ad364e35_10.0.19041.680_none_021ebd345a75567f
│   │       ├───amd64_microsoft-windows-s..stack-inetsrv-extra_31bf3856ad364e35_10.0.19041.680_none_16f82254009eecc1
│   │       ├───amd64_microsoft-windows-s..stack-termsrv-extra_31bf3856ad364e35_10.0.19041.680_none_f098d9f99ea89093
│   │       ├───amd64_microsoft-windows-servicingstack-inetsrv_31bf3856ad364e35_10.0.19041.680_none_12f53731c5ece5e4
│   │       ├───amd64_microsoft-windows-servicingstack-onecore_31bf3856ad364e35_10.0.19041.680_none_1c18fdd47e42b752
│   │       ├───amd64_microsoft-windows-servicingstack_31bf3856ad364e35_10.0.19041.680_none_e72768c3263f99bc
│   │       ├───x86_microsoft-windows-s..-installers-onecore_31bf3856ad364e35_10.0.19041.680_none_6d65dc8a4bfe1866
│   │       ├───x86_microsoft-windows-s..cingstack-onecoreds_31bf3856ad364e35_10.0.19041.680_none_3601e9bac8430bb9
│   │       ├───x86_microsoft-windows-s..ck-mof-onecoreadmin_31bf3856ad364e35_10.0.19041.680_none_9b6b5550d5ad80a2
│   │       ├───x86_microsoft-windows-s..formers-shell-extra_31bf3856ad364e35_10.0.19041.680_none_6bb8389c23c138f5
│   │       ├───x86_microsoft-windows-s..gstack-boot-onecore_31bf3856ad364e35_10.0.19041.680_none_d7708fc81712b5dd
│   │       ├───x86_microsoft-windows-s..ingstack-base-extra_31bf3856ad364e35_10.0.19041.680_none_a0ae571469eb407f
│   │       ├───x86_microsoft-windows-s..k-transformers-core_31bf3856ad364e35_10.0.19041.680_none_eddd06a27c08bc17
│   │       ├───x86_microsoft-windows-s..llers-onecore-extra_31bf3856ad364e35_10.0.19041.680_none_a5842f2469d098df
│   │       ├───x86_microsoft-windows-s..ngstack-onecorebase_31bf3856ad364e35_10.0.19041.680_none_722e61c0887bcaf7
│   │       ├───x86_microsoft-windows-s..ransformers-onecore_31bf3856ad364e35_10.0.19041.680_none_a60021b0a217e549
│   │       ├───x86_microsoft-windows-s..stack-termsrv-extra_31bf3856ad364e35_10.0.19041.680_none_947a3e75e64b1f5d
│   │       ├───x86_microsoft-windows-servicingstack-inetsrv_31bf3856ad364e35_10.0.19041.680_none_b6d69bae0d8f74ae
│   │       ├───x86_microsoft-windows-servicingstack-onecore_31bf3856ad364e35_10.0.19041.680_none_bffa6250c5e5461c
│   │       └───x86_microsoft-windows-servicingstack_31bf3856ad364e35_10.0.19041.680_none_8b08cd3f6de22886
│   └───SharedFileCache
├───PostRebootEventCache.V2
└───SLS
    ├───2B81F1BF-356C-4FA1-90F1-7581A62C6764
    ├───522D76A4-93E1-47F8-B8CE-07C937AD1A1E
    ├───7971F918-A847-4430-9279-4A52D1EFE18D
    ├───855E8A7C-ECB4-4CA3-B045-1DFA50104289
    ├───8B24B027-1DEE-BABB-9A95-3517DFB9C552
    ├───9482F4B4-E343-43B6-B170-9A65BC822C77
    └───E7A50285-D08D-499D-9FF8-180FDC2332BC

dism 中出现了一些错误,整个日志太长,无法在此处发布,我设法让 dism 日志生成,然后将其上传到 Google Drive:

https://drive.google.com/file/d/1HbsPtZ79KVQqaYMGLVA4jA4fMSef2iLC/view

该怎么办?

更新:打开文件夹C:\Windows\Logs\CBS,里面有多个文件,将其压缩并上传到Google Drive:

https://drive.google.com/file/d/1gwRGCq1mJAp6S6J_mN8hnfw9A91hqSWb/view?usp=sharing

温弗:

在此处输入图片描述

这是更新历史记录,奇怪的是一切都成功安装,我根据日期推断问题根源是 KB4592438:

在此处输入图片描述

目前有两个更新等待重启:

在此处输入图片描述

如何摆脱它们?

Get-WindowsUpdatelog 的输出:

https://drive.google.com/file/d/1dUPilcqpapLpzQzv7QVf9fzeVt37qq64/view?usp=sharing

我应该删除哪些文件,删除哪些注册表项才能取消待处理的更新?我可以删除 SoftwareDistribution 文件夹吗?

很奇怪,我运行了以下命令:

Get-WindowsPackage -Online | Where {$_.PackageName -match "KB4592438"}
Get-WindowsPackage -Online | Where {$_.PackageName -match "KB4586876"}

没有回应

在更新历史记录中,KB4592438 已于 2020-12-26 成功安装,但不知何故仍处于等待重启状态

尝试过

wusa /uninstall /kb:4592438
wusa /uninstall /kb:4586876

结果(两者的错误相同):

在此处输入图片描述

我曾尝试过这些:

net stop wuauserv
rd /s /q %systemroot%\SoftwareDistribution\Download
net start wuauserv
dism.exe /online /cleanup-image /revertpendingactions

没有发生错误,更新仍然待处理,仍然在恢复...我现在可以取消它吗?

已完成:

Deployment Image Servicing and Management tool
Version: 10.0.19041.572

Image Version: 10.0.19042.631

Reverting pending actions from the image...
The operation completed. Revert of pending actions will be attempted after the reboot.
The operation completed successfully.

更新仍未完成...

我打开了 C:\Windows\WinSxs\Temp 并发现里面有很多项目,由于它被命名为 Temp,我猜想它只与待处理的操作有关,删除该文件夹安全吗?在确认之前我不会删除它,我现在正在重新启动计算机。

答案1

连续四次重启后没有出现“...撤消更改”蓝屏,我可以确认我已经解决了它;

我已经跑过:

(Get-WindowsPackage -Online | Where {$_.PackageState -eq "Staged" -or $_.PackageState -eq "InstallPending"}).PackageName | %{dism /Online /Remove-Package /PackageName:${_} /norestart}

不知道是否有贡献,不知道是否相关;

我认为这个问题可以通过以下方式解决(不确定,但肯定相关):

net stop wuauserv
rd /s /q %systemroot%\SoftwareDistribution\Download
net start wuauserv
dism /online /cleanup-image /revertpendingactions
dism /online /cleanup-image /startcomponentcleanup

现在“设置”显示我的设备已更新至最新版本:

在此处输入图片描述

但我仍然不知道到底是什么原因造成的...但是我想取消待处理的重启更新以防止失败并回滚,这肯定可以解决问题。

如果您想调查原因,请点击这里:

https://drive.google.com/file/d/1dLShNyo_ww3_QBmpdWJdzwQiC_YI2cMk/view?usp=sharing

相关内容