Skip to content
Tech Shizz Logo

An Engineers Blog

  • TechShizz
  • blog

Use DISM to repair corrupt operating systems

Posted on February 23, 2021 By rich No Comments on 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:Sourcesinstall.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:SourcesInstall.wim:4
From OS
DISM /online /Cleanup-Image /RestoreHealth /Source:WIM:E:SourcesInstall.wim:4
(Where E= your ISO drive letter and 4 = your OS edition)
This should clean the image.

Post navigation

❮ Previous Post: Office 365 Client Connection Troubleshooting
Next Post: How to Stop Windows 7 or 8 from Downloading Windows 10 Automatically ❯

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors

Subscribe to our newsletter!

Recent Posts

  • How to implement a lightning-fast ransomware playbook
  • How to achieve defence in depth in your business
  • How to implement a SecOps team phishing response plan
  • How to block an Office 365 Sign-in correctly
  • Microsoft finally patched serious Exchange 0-day over a month old!

Recent Comments

    Archives

    • November 2022
    • July 2021
    • March 2021
    • February 2021

    Categories

    • Cyber Security
    • Uncategorized

    Meta

    • Log in
    • Entries feed
    • Comments feed
    • WordPress.org

    Copyright © 2023 .

    Theme: Oceanly News Dark by ScriptsTown