I needed to do this recently when we had a problem with an installed Windows Update that was causing random BSOD on both Server 2008 and Server 2012,
I needed to do this recently when we had a problem with an installed Windows Update that was causing random BSOD on both Server 2008 and Server 2012, didn’t see to affect Server 2016.
First I mounted the crashed VM’s vmdk file (the one with Windows installed, in case you have multiple disks) to a known good working Virtual Machine as an existing Hard Drive.
The drive mounted as I: drive
List the installed packages on the failed system:
dism /image:i: /get-packages /format:table
You can also output this to a file to make it easier
dism /image:i: /get-packages /format:table > patches.txt
To remove the package you simply use:
DISM.exe /image:i: /Remove-Package /PackageName:Package_for_KB2870699~31bf3856ad364e35~amd64~~6.2.1.1 /quiet /norestart
Or you could remove multiple packages by creating a PowerShell script such as (this is only an example and all scripts should contain some type of error trapping):
DISM /online /Remove-Package /PackageName:Package_for_RollupFix~31bf3856ad364e35~amd64~~7601.24002.1.4 /quiet /norestart write-host “Removed Update 1 of 9” DISM /online /Remove-Package /PackageName:Package_for_RollupFix~31bf3856ad364e35~amd64~~7601.24055.1.3 /quiet /norestart write-host “Removed Update 2 of 9” DISM /online /Remove-Package /PackageName:Package_for_RollupFix~31bf3856ad364e35~amd64~~7601.24076.1.2 /quiet /norestart write-host “Removed Update 3 of 9” DISM /online /Remove-Package /PackageName:WUClient-SelfUpdate-ActiveX~31bf3856ad364e35~amd64~~7.6.7600.256 /quiet /norestart write-host “Removed Update 4 of 9” DISM /online /Remove-Package /PackageName:WUClient-SelfUpdate-ActiveX~31bf3856ad364e35~amd64~~7.6.7600.320 /quiet /norestart write-host “Removed Update 5 of 9” DISM /online /Remove-Package /PackageName:WUClient-SelfUpdate-Aux-TopLevel~31bf3856ad364e35~amd64~~7.6.7600.320 /quiet /norestart write-host “Removed Update 6 of 9” DISM /online /Remove-Package /PackageName:WUClient-SelfUpdate-Core-TopLevel~31bf3856ad364e35~amd64~~7.6.7600.256 /quiet /norestart write-host “Removed Update 7 of 9” DISM /online /Remove-Package /PackageName:WUClient-SelfUpdate-Core-TopLevel~31bf3856ad364e35~amd64~~7.6.7600.320 /quiet /norestart write-host “Removed Update 8 of 9” DISM /online /Remove-Package /PackageName:WUClient-SelfUpdate-Aux-TopLevel~31bf3856ad364e35~amd64~~7.6.7600.256 /quiet /norestart write-host “Removed Update 9 of 9”
If you wanted to use this to remove packages from a running Windows system you could use the following:
List the installed packages on the failed system:
dism /online /get-packages /format:table
You can also output this to a file to make it easier
dism /online /get-packages /format:table > patches.txt
To remove the package you simply use:
DISM.exe /online /Remove-Package /PackageName:Package_for_KB2870699~31bf3856ad364e35~amd64~~6.2.1.1 /quiet /norestart
COMMENTS