TechShizz | Use DISM to repair corrupt operating systems

Use DISM to repair corrupt operating systems

DISM can be used (like SFC /Scannow) to repair system os files. DISM is better, because if uses source files you specify to repair the corruptions. The advantage of this is apparent when a machine might be powered off during windows updates and the source files get corrupted. SFC might not be able to repair the files but with a windows ISO and DISM you can repair the OS without issue.

1. Burn your Windows ISO to a USB/DVD
2. Boot your machine up using the USB/DVD
3. SHIFT + F10 to enter Command prompt
4. Identify each drive and it letter connected.
Use:
Diskpart
list disk
select disk (X)
detail disk
5. Once you know which letter your USB/DVD media has you need to find the Index of your OS.
DISM /get-wiminfo /wimfile:E:\Sources\install.wim


6. Next we start the clean image process. If you cannot boot up windows, this command will differ. To run this command while in CMD from a recovery disk use the /Image parameter:
Dism.exe /Image:C:\ /Cleanup-Image /StartComponentCleanup
To run this while the OS is booted run it like this:
Dism.exe /online /Cleanup-Image /StartComponentCleanup

7. As above the following command depends on if the OS is running or not:
From WinPE
DISM /Image:C:\ /Cleanup-Image /RestoreHealth /Source:WIM:E:\Sources\Install.wim:4
From OS
DISM /online /Cleanup-Image /RestoreHealth /Source:WIM:E:\Sources\Install.wim:4
(Where E= your ISO drive letter and 4 = your OS edition)

This should clean the image.

Pingbacks and trackbacks (1)+

Add comment