Need help: How do I use DISM offline repair Windows 10 system image?
“I have a machine running Win10 that was fine. But it would not boot one day. I tried my normal steps (eg: safe mode, system restore, sfc, bootrec) without success.” And then, I tried DISM in the offline mode and failed again. The command I used was:
DISM.exe /Image:d:\ /Cleanup-image /Restorehealth /Source:d:\w10\install.wim /LimitAccess /scratchdir:d:\scratch
I wonder if the syntax is wrong or how to use DISM offline repair Windows 10."
I'm sorry but honestly, your command line lack of \offline parameter. You can choose to add it and try again. If it still not working, the DISM.exe may not detect the image. To solve it, you need to mount the Windows ISO first and then try again.
If you don't how to make it, you can continue to see below and learn the detailed steps to use DISM offline repair Windows 10.
What is DISM?
DISM, short for Deployment Image Servicing and Management (DISM.exe), is a command-line tool that can be used to service and prepare Windows images (with .wim or .vhd or vhdx format), including those used for Windows PE, Windows Recovery Environment (Windows RE) and Windows Setup.
In general, it will download necessary files from Windows Update to replace the bad file. But if there are problems or you are not connected to the internet, DISM may fail to repair the corrupted image. In this case, you can try DISM offline command-line with source option.
You can use an "install.wim" or "install.esd" file from another computer, bootable install media, or Windows 10 ISO file. Please be sure these files must be of the same version, edition as well as language of the operating system you are using.
How to use DISM offline repair Windows 10/11
Here you will use DISM with /Online switch and \offline switch to repair or prepare backup image. First, let's get the difference between them and understand how it works.
/Online switch: It's used to target the current running operating system. There are two requirements: first, the computer is booted into the operating system. Second, the backup image is recaptured and the DISM.exe can detect it.
\Image switch: It's used to target offline Windows image, and it's usually a WIM, VHD or VHDX file.
As the switch meaning suggest, it seems that you need to use DISM \offline to repair Windows 10. And some users report that DISM says it can’t find source files while using DISM /Online.
But that's not exactly the case. you still can use DISM /Online to complete the offline image repair if you mount these offline images first.
Then, you may wander how to perform DISM repair Windows 10 offline step by step. Please continue to see below.
Method 1: Perform DISM repair Windows 10/11 offline using DISM /Online
Part 1: Mount offline image for preparation
Step 1. Download Windows 10 1809 ISO from Microsoft support website.
Step 2. Open the MediaCreationToolxxx.exe file to access its setup window, and click Accept to agree with license terms.
Step 3. In the "What do you want to do?" window, select "Create installation media (USB flash drive, DVD or ISO file) for another PC". Then, click Next.
Step 4. Select language, architecture, and edition, and then click Next.
Step 5. In the "choose which media to use" window, select ISO file and click Next.
Step 6. Then, select a backup destination to store the ISO file and click Save.
Step 7. In the last window, you will be asked to burn the ISO file to a DVD. Click the link below to open the file location with File Explorer, right-click the ISO file and select Mount to recapture the image.
Step 8. Confirm the drive letter for the recaptured image and remember it. It saves the install.wim file you will use to repair offline image to the source folder. If the drive letter is F:, you need to set the source path as F:\source.
Part 2: Perform DISM offline repair in Windows 10 step by step
Step 1. Press WIN + X and select Command Prompt(Admin) in the search result list.
Step 2 (optional). Type the following commands to clean up the component store and analyze its size. Please remember to hit Enter after each command.
DISM /Online /Cleanup-Image /StartComponentCleanup
DISM /Online /Cleanup-Image /AnalyzeComponentStore
Step 3. Type the following command to repair Windows image with the known good files from install.wim file. Hit Enter is required.
DISM /Online /Cleanup-Image /RestoreHealth /source:F:\Sources\Install.wim:1 /LimitAccess
Note: The parameter /LimitAccess is to restrict the use of Windows Update.
Method 2: Perform DISM offline repair in Windows 10/11 with DISM /Image
Except for DISM /online, you can directly use DISM /offline to perform DISM offline repair in Windows 10. This process requires the offline backup path to the root directory. Below are the steps:
Step 1. Run command prompt with priority.
Step 2. Type the following command and hit Enter to execute DISM offline repair Windows 10 using ISO file.
Dism /Image: C:\offline /Cleanup-Image /RestoreHealth /Source: c:\test\mount\windows
Protect your Windows 10/11 system instead of repair
Computer failure and other errors may occur at any time, but you may install multiple programs or store many data on the computer. If you don't want to lose them, you can choose to backup your computer and save the image to a safe place. It gives you a chance to restore your computer easily and quickly in a few clicks.
To make it, you need the best backup freeware for Windows 11/10/8/7/XP/Vista - AOMEI Backupper Standard. Below are the benefits of it:
- It offers complete backup solutions for your computer, including System Backup, Disk Backup, Partition Backup, and File Backup.
- It allows you to schedule backup on basis of daily/weekly/monthly, so that you can keep the data up-to-date and accurately restore to any previous version.
- It provides different backup methods, including full backup, incremental backup, differential backup. You can use it to backup a full copy of your data or only the changed part.
- It works well in multiple backup storages, such as internal disk, external hard drive, USB disk, cloud drive, network share/NAS, etc.
- it has a clean interface and user-friendly design, so users can easily understand and use it smoothly.
Furthermore, if you don't have any previous backup and DISM unluckily fails to repair Windows 10/11, you could create system backup on another working PC, and restore the system image to different hardware with an advanced edition like AOMEI Backupper Professional.
Now, let's see how to create a system image with it first.
Step 1. Download the best free backup software - AOMEI Backupper, install and launch it. Then, you will see its deed-blue screen.
Step 2. Click Backup and System Backup in order.
Step 3. Select a location for your backup. If you want to backup to USB drive, you need to insert it into your computer.
Step 4. At the lower location of system backup, you can see "Options", "Schedule" and "Scheme" three options. Click them to customize backup settings. Then, confirm everything is ok and click Start Backup.
Option: You can comment on a task, set compression level, enable email notification, etc.
Schedule: It includes daily/weekly/monthly in Standard edition and performs incremental backup by default. If you upgrade to Pro edition, you can choose event triggers/USB plug in, or set up a scheduled differential backup.
Scheme: It enables you to create a rule for auto deleting backups so as to save storage space. It's available in advanced editions only.
To restore Windows 10, you just need to find the backup task in Home page or go to Restore tab and locate the system image, then follow the wizard to complete the operation. If the system image is created on another PC with different hardware, remember to tick Universal Restore (supported by advanced editions).
- In case the computer cannot boot due to system errors, you could create bootable media ahead of time. Alternatively, you could also use the Recovery Environment tool to enable a boot option for quick recovery.
- If you want to use this software on multiple Windows computers without installing, you can create portable version (supported by Tech and Tech Plus edition) of it on removable device. Then, you can take it everywhere.
Reading here, you may already know how to use DISM offline repair Windows 10 image. But it's not easy to master because of the complicated syntax. Therefore, it's suggested to create a system image backup to avoid computer failure ahead of time. If something bad happens, you can restore system image from external hard drive and get your computer back in a very short time.
AOMEI Backupper Standard is not only a free backup software but also disk cloning software. Thus, you can use it to replace laptop HDD with SSD, clone NVMe to NVMe SSD, clone HDD to Samsung SSD, migrate OS to SSD, etc. And you can directly use it to replace bad disk without restoring image first. You can download this software to have a try if you need to protect your computer.