Apply Windows Image using DISM Instead of Clean Install  

Page 1 of 2 12 LastLast
    Apply Windows Image using DISM Instead of Clean Install

    Apply Windows Image using DISM Instead of Clean Install

    How to Apply Windows Image using DISM Instead of Clean Install to Reduce Time
    Published by Category: Installation & Upgrade
    13 May 2017
    Designer Media Ltd


    information   Information
    The most boring part of computing is waiting operating system to be installed. Installing Windows 10 can take anything from 10 to over 30 minutes (depending on hardware). The low end i5 laptop I am using to write this tutorial with an HDD instead of SSD takes on average of 35 minutes from booting with install USB flash drive to OOBE to start with region selection dialog after last restart required by setup, additional 3 to 4 minutes to get initial user created and wait Windows preparing user profile and getting to desktop.

    Of course on state of the art hardware, especially using SSD instead of HDD the time needed to install is only about a third of what I need with this hardware.

    Whatever hardware you have, applying Windows install image with DISM (Deployment Image Servicing and Management tool) instead of traditional clean install will significantly reduce the time needed to install Windows. Especially when installing using a customized and personalized Windows image with pre-installed software (see tutorial) you can reduce the time by up to over 50% but even when using a standard Windows install media you get Windows installed at least over 20% faster.

    You can use any valid Windows 10 install media, be it made from a self made ISO from Windows Insider or Feature Upgrade (tutorial), a WIM based original ISO Microsoft has available for Windows Insiders (download link in tutorial), or an ESD based ISO made with Media Creation Tool (download link in tutorial).

    This tutorial although written for Windows 10 also applies to Windows 7, 8 & 8.1.





    Apply Windows Image using DISM Instead of Clean Install Contents Apply Windows Image using DISM Instead of Clean Install
     Click links to jump to any part


    Part One: Boot & Partitioning
    Part Two: Apply Windows image
    Part Three: Done!




    Apply Windows Image using DISM Instead of Clean Install Part One Apply Windows Image using DISM Instead of Clean Install
     Boot & Partitioning

    1.1)
    Boot PC from Windows install media (DVD or USB flash drive), continue as in normal clean install until you get to disk options screen. Skip the product key when asked:
    Name:  Skip key.png
Views: 15729
Size:  24.4 KB

    1.2) If disk is unallocated, click New:
    Name:  Allocate 1.png
Views: 14935
Size:  25.8 KB

    (If hard disk is already partitioned as you wish, jump to step 1.5. If you want to wipe an already partitioned disk select existing partitions one by one, select Delete, and when done continue from 1.3.)

    1.3) Set the preferred size of Windows partition (#1 in screenshot) and click Apply (#2). If you want to use whole disk for a single Windows partition just accept default value and click Apply:
    Name:  Allocate 2.png
Views: 14893
Size:  42.2 KB

    1.4) Click OK:
    Name:  Accept allocation.png
Views: 14833
Size:  25.7 KB

    1.5) On BIOS based machine with MBR disk setup will now create the required System Reserved partition (500 MB) using the rest of allocated space for Windows partition.

    On UEFI based machine with GPT disk the Recovery partition (450 MB), EFI System partition (99 MB) and Microsoft Reserved partition (MSR, 16 MB) will be created, rest of the allocated space being used for Windows partition.

    1.6) Select the partition where Windows will be installed (Primary partition) and click Format.

    BIOS / MBR:
    Name:  Format C MBR.png
Views: 14916
Size:  117.8 KB

    UEFI / GPT:
    Name:  Format C GPT.png
Views: 14927
Size:  37.4 KB

    1.7) If you did not allocate whole disk for Windows partition, you can leave rest of the disk now unallocated. When Windows has been installed you can use Disk Management to partition remaining space as you wish.

    Tip   Tip
    If you want to allocate a specific amount of space for Windows partition, add 500 MB on BIOS / MBR systems and 565 MB on UEFI / GPT systems.

    Example (MBR):
    • You want to have a 150 GB Windows partition on a BIOS / MBR system, you should allocate 154,100 MB
      (150 * 1024 MB = 153,600 MB = 150 GB plus 500 MB for System reserved partition)

    Example (GPT):
    • You want to have a 250 GB Windows partition on a UEFI / GPT system, you should allocate 256,565 MB
      (250 * 1024 MB = 256,000 MB = 250 GB plus 450 MB Recovery, 99 MB EFI and 16 MB MSR partitions)


    1.8) Setup does not show any message when formatting is done. Only indicator of progress is mouse pointer; when formatting, pointer will be an hourglass icon. When ready normal arrow pointer will be shown. Formatting even big hard disks only takes a few seconds.

    1.9) When Windows partition has been formatted close Disk Options dialog. This takes you back to Windows Setup screen:
    Name:  Exit partitioning.png
Views: 14889
Size:  41.6 KB

    Note   Note
    Advanced users can of course use DISKPART to partition HDD / SSD instead of steps told above.





    Apply Windows Image using DISM Instead of Clean Install Part Two Apply Windows Image using DISM Instead of Clean Install
     Apply Windows image

    2.1)
    Back on Windows Setup screen, press SHIFT + F10 to open Command Prompt:
    Click image for larger version. 

Name:	SHIFT+F10.jpg 
Views:	354 
Size:	70.9 KB 
ID:	134902

    2.2) Type diskpart and press Enter to start Disk Partition Utility (see #1 in screenshot in step 2.5)

    2.3) Type list vol and press Enter to see list of volumes / partitions (#2). Note the temporarily assigned drive letters for your newly formatted Windows partition and install media (#3). You recognize Windows partition from its size and install media by its type, Removable if using USB flash drive or DVD-ROM if using a DVD install media

    2.4) Type exit and press Enter to quit Disk Partition Utility (#4)

    2.5) Enter following command to check correct index for your preferred Windows 10 edition replacing highlighted drive ID letter with your actual install media ID (#5). Note the index# for edition you want to install (#6):

    WIM based install media (Insider or self made ISO):
    dism /Get-WimInfo /WimFile:D:\Sources\install.wim
    ESD based install media (ISO made using Media Creation Tool):
    dism /Get-WimInfo /WimFile:D:\Sources\install.esd
    Name:  Diskpart DISM Index.jpg
Views: 15111
Size:  107.8 KB

    2.6) In this example case now the temporary drive ID for partition where I want Windows to be installed is G:, Windows install media (USB drive) is D:, and as I want to install Windows 10 PRO the index# is 1. That's all information I need to apply Windows image (install.wim or install.esd file from Sources folder on install media).

    2.7) Enter following command, replacing drive ID letters and Windows edition index# with your actual ones (#1 in screenshot in step 2.9):

    dism /Apply-Image /ImageFile:D:\Sources\install.wim /index:1 /ApplyDir:G:\

    • ImageFile = Path to install.wim file on install media (install.esd file on media created with Media Creation Tool)
    • ApplyDir = temporary drive ID for partition where Windows will be installed followed by :\

    2.8) DISM will now apply Windows image to selected partition (G: in this example). This partition will get the correct drive ID C: when image has been applied and Windows restarted. When DISM is ready you can check that Windows system folders have been created with DIR G: command (#2)

    2.9) Only one thing missing: we need to create boot records with BCDBOOT command. We can find it on newly created Windows partition, in Windows\System32 folder. Enter following command to write boot records to make hard disk bootable (#3):

    G:\Windows\System32\bcdboot G:\Windows
    Click image for larger version. 

Name:	Write boot records.jpg 
Views:	686 
Size:	73.9 KB 
ID:	134905





    Apply Windows Image using DISM Instead of Clean Install Part Three Apply Windows Image using DISM Instead of Clean Install
     Done!

    3.1) Close Command Prompt, close Windows Setup:
    Name:  Close setup.jpg
Views: 14739
Size:  22.6 KB

    3.2) Setup thinks now you want to cancel installation, not knowing that Windows has already been installed . Just click Yes to let PC restart:
    Name:  Yes - finish setup.jpg
Views: 14717
Size:  21.7 KB

    3.3) Windows will now restart booting from hard disk entering the final phase of setup, Windows Welcome (OOBE) Mode. Select your region, add initial user profile and you are done


    That's it!

    Kari

  1. Posts : 1,500
    Windows 10 Pro (32-bit) 16299.15
       05 Oct 2017 #1

    Hi Kari,
    Does this tutorial include setting up the Recovery partition?
    I wondered if another step was required to copy winre.wim onto there, and then a reagentc step to link to it?
      My ComputerSystem Spec

  2. Kari's Avatar
    Posts : 15,138
    Windows 10 Pro
    Thread Starter
       07 Oct 2017 #2

    DavidY said: View Post
    Hi Kari,
    Does this tutorial include setting up the Recovery partition?
    I wondered if another step was required to copy winre.wim onto there, and then a reagentc step to link to it?
    Sorry for delayed reply.

    If you follow the instructions in this tutorial to the letter, EFI, WinRE and MSR partitions will be created exactly as when doing a traditional install. No additional actions are required.
      My ComputerSystem Spec


  3. Posts : 1,500
    Windows 10 Pro (32-bit) 16299.15
       08 Oct 2017 #3

    Kari said: View Post
    Sorry for delayed reply.

    If you follow the instructions in this tutorial to the letter, EFI, WinRE and MSR partitions will be created exactly as when doing a traditional install. No additional actions are required.
    Thanks Kari,

    I did try it out in the end, and as you say, it does populate the recovery partition with the recovery tools.
    I wondered what point that gets done - is it during the OOBE phase I wonder?
      My ComputerSystem Spec

  4. Kari's Avatar
    Posts : 15,138
    Windows 10 Pro
    Thread Starter
       08 Oct 2017 #4

    I am not sure at which point EFI and WinRE will be populated, can't find any documentation about it.
      My ComputerSystem Spec


  5. Posts : 213
    Microsoft Windows 10 x64
       08 Oct 2017 #5

    this nice method works on Hyper-V Virtual Machine also

    I attached a Windows ISO 1703 (April 2017) as the first DVD for boot
    I put a copy of [ 16299.15.170928-1534.rs3_release_clientconsumer_ret_x64fre_en-us...........esd ] (Sept 2017) on an second ISO DVD with ImgBurn

    I followed your instructions above

    I now have a clean W10-1709 virtual machine

    So simple in fact when you know

    thanks Kari

    some pictures









    Last edited by D4ni3l; 08 Oct 2017 at 08:08.
      My ComputerSystem Spec

  6.    24 Mar 2018 #6

    Hi @Kari,

    After todays online forums, I gave this a go (installing as dual boot). I ran into a couple of problems:-

    1) I just cannot boot from a 17128 iso no matter what I try. I got round this by booting from a Macrium Reflect Winpe image and running Dism from there, and it worked fine. Hell it is a lot faster!

    I then booted into my normal windows, and added a boot entry. Then I ran into next problem.


    2) I selected the 17128 installation from the dual boot menu, and it just would not boot into the new installation, just getting into a reboot loop and eventually ending back at dual bot menu after quite some time. I then used the Macrium Deploy option and selected the 17128 installation and BAM - it booted straight to OOBE in seconds.

    Running deploy, it complained about the standard SATA controller and let me install the AMD version, which I always had to manually install after a clean install, and worked. So I am guessing there is some incompatibility with the standard windows SATA controller and 17128 (1803 versions) on AMD pc.

    Now I know what to do, I can clean install fine on host pc now.

    Many thanks for advice and this great guide, even if I do it a little differently.


    Thinking about it, I probably do not even need to boot to a winpe drive to run dism if installing a dual boot?

    Edit: Indeed, dism can be run from normal windows to clean install a dual boot version. Very nice.


    So key steps:-

    Create an install.wim using @Kari's uuptoiso tool.

    Shrink C drive by say 50GB

    Create new partition in newly unallocated space

    Deploy image with dism from an admin command prompt

    Add boot entry from admin command prompt

    Boot pc - select new installation

    Beauty of this method is you an carry on using existing windows for most of it.

    Obviously, if not dual booting i.e. only single booting, you will have to boot first into a win pe environment to run dism etc.
    Last edited by cereberus; 24 Mar 2018 at 15:23.
      My ComputerSystem Spec

  7.    25 Mar 2018 #7

    cereberus said: View Post
    Hi @Kari,

    After todays online forums, I gave this a go (installing as dual boot). I ran into a couple of problems:-

    1) I just cannot boot from a 17128 iso no matter what I try. I got round this by booting from a Macrium Reflect Winpe image and running Dism from there, and it worked fine. Hell it is a lot faster!

    I then booted into my normal windows, and added a boot entry. Then I ran into next problem.


    2) I selected the 17128 installation from the dual boot menu, and it just would not boot into the new installation, just getting into a reboot loop and eventually ending back at dual bot menu after quite some time. I then used the Macrium Deploy option and selected the 17128 installation and BAM - it booted straight to OOBE in seconds.

    Running deploy, it complained about the standard SATA controller and let me install the AMD version, which I always had to manually install after a clean install, and worked. So I am guessing there is some incompatibility with the standard windows SATA controller and 17128 (1803 versions) on AMD pc.

    Now I know what to do, I can clean install fine on host pc now.

    Many thanks for advice and this great guide, even if I do it a little differently.


    Thinking about it, I probably do not even need to boot to a winpe drive to run dism if installing a dual boot?

    Edit: Indeed, dism can be run from normal windows to clean install a dual boot version. Very nice.


    So key steps:-

    Create an install.wim using @Kari's uuptoiso tool.

    Shrink C drive by say 50GB

    Create new partition in newly unallocated space

    Deploy image with dism from an admin command prompt

    Add boot entry from admin command prompt

    Boot pc - select new installation

    Beauty of this method is you an carry on using existing windows for most of it.

    Obviously, if not dual booting i.e. only single booting, you will have to boot first into a win pe environment to run dism etc.
    This should work , Thanks
      My ComputerSystem Spec

  8.    27 Mar 2018 #8

    cereberus said: View Post
    Hi @Kari,

    After todays online forums, I gave this a go (installing as dual boot). I ran into a couple of problems:-

    1) I just cannot boot from a 17128 iso no matter what I try. I got round this by booting from a Macrium Reflect Winpe image and running Dism from there, and it worked fine. Hell it is a lot faster!

    I then booted into my normal windows, and added a boot entry. Then I ran into next problem.


    2) I selected the 17128 installation from the dual boot menu, and it just would not boot into the new installation, just getting into a reboot loop and eventually ending back at dual bot menu after quite some time. I then used the Macrium Deploy option and selected the 17128 installation and BAM - it booted straight to OOBE in seconds.

    Running deploy, it complained about the standard SATA controller and let me install the AMD version, which I always had to manually install after a clean install, and worked. So I am guessing there is some incompatibility with the standard windows SATA controller and 17128 (1803 versions) on AMD pc.

    Now I know what to do, I can clean install fine on host pc now.

    Many thanks for advice and this great guide, even if I do it a little differently.


    Thinking about it, I probably do not even need to boot to a winpe drive to run dism if installing a dual boot?

    Edit: Indeed, dism can be run from normal windows to clean install a dual boot version. Very nice.


    So key steps:-

    Create an install.wim using @Kari's uuptoiso tool.

    Shrink C drive by say 50GB

    Create new partition in newly unallocated space

    Deploy image with dism from an admin command prompt

    Add boot entry from admin command prompt

    Boot pc - select new installation

    Beauty of this method is you an carry on using existing windows for most of it.

    Obviously, if not dual booting i.e. only single booting, you will have to boot first into a win pe environment to run dism etc.
    You can also use this to install to a virtual hard drive instead of creating a new partition. Using Macrium Reflect Redeploy as I did is a little trickier as you have to attach the virtual disk from the Macrium Reflect Command prompt first using diskpart commands, but only take a minute to do.
      My ComputerSystem Spec

  9.    31 Mar 2018 #9

    Today, I tried an experiment - I wanted to clean install Skip Ahead in a hyper-v vm, and normally it takes ages on my laptop. I followed the guide booting from skippy iso up to point of having created all the required partitions, and then shutdown VM.

    I then went to host, and attached vhd as a drive using disk management, and used dism from host to deploy OS instead.

    I then detached vhd from host, and booted to skippy iso, and created boot entry, booted vm and it went as I hoped straight to oobe.

    Doing dism on host rather than in vm is much quicker on my laptop.

    I then made a copy of vhd, mounted as drive in host, made a boot entry. I tried rebooting to host but it failed as cases in previous post. I rebooted into Macrium Reflect, added vhd using diskpart and ran Macrium Redeploy, and as before BAM on rebooting, straight to oobe.

    Doing it this way, means I can install on vm and dual boot on host with essentially only one main installation phase. You have to do it via vm first to ensure drive has all the partitions needed to boot in vm.
      My ComputerSystem Spec


 
Page 1 of 2 12 LastLast

Tutorial Categories

Apply Windows Image using DISM Instead of Clean Install Tutorial Index Network & Sharing Instalation and Upgrade Browsers and Email General Tips Gaming Customization Apps and Features Virtualization BSOD System Security User Accounts Hardware and Drivers Updates and Activation Backup and Restore Performance and Maintenance Mixed Reality Phone


Related Threads
Apply Windows 10 Enterprise image via USB in Installation and Upgrade
I have taken an image using DISM and it is in the .wim format. I want to apply it to a tablet using a usb stick, it has a UEFI Bios. in the past with windows 7 and I have been able to create a bootable usb drive by using Windows 7 USB DVD tool to...
This isn't a major problem, but I would just like to understand how it happened. Some background. This is a Windows 10 clean install on a new SSD drive. The original HDD is still in the computer with a corrupt version of Windows 8 on it. My...
Hi guys, so a few days ago my windows 10 crashed so I had to format and reinstall windows 7 then upgrade to windows 10, a hard work to do. So I started to search about how to capture the image of C: where the windows 10 is running and I found Dism....
Hi I installed Windows ADK 10 v1511 on Windows 10 v1511 Enterprise 64 bit. I typed the following commands: Dism /Apply-Image /ImageFile:"<wim_File_Path>\install.wim" /Index:1 /ApplyDir:"<Apply_Directory_Path>" /Verify /CheckIntegrity...
Solved creating usb pen for dism apply-image in Installation and Upgrade
I have managed to create a USB pen drive to apply WIM images using the DISM Apply-image command in 64bit so I know it can be done but any ideas how to create a pen to apply 32bit WIM images
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 02:00.
Find Us