This page has been robot translated, sorry for typos if any. Original content here.

How to Unzip a WIM Image File

Как распаковать файл образа WIM

The WIM file is a Microsoft format, in which the Windows installation packages are packed inside the ISO image.

Contrary to the common misconception, the wonderful 7-Zip program could not unzip the image from Windows 2012.

However, the microsoft has taken care of this, for unpacking WIM files is a special utility ImageX.

But on Windows 7 and above, you can do with the standard tools.

First you need to know the name of the image inside the WIM file, because in the meme in the general case (and this is usually the case) several versions of the operating system can be packed:

dism /Get-WimInfo /WimFile:"f:\Inst\Win2012\SW_DVD5_Win_Svr_Std_and_DataCtr_2012_64Bit_Russian_Core_MLF_X18-27640\sources\install.wim"

Where:

  • dism - program for working with WIM files;
  • / Get-WimInfo - the key that tells it to show information about the available images;
  • / WimFile: - after this key, the full path to the WIM file is specified.

As a result, dism showed such a list:

Index: 1
Name: Windows Server 2012 SERVERSTANDARDCORE
Description: Windows Server 2012 SERVERSTANDARDCORE
Size (byte): 7,461,623,448

Postal code: 2
Name: Windows Server 2012 SERVERSTANDARD
Description: Windows Server 2012 SERVERSTANDARD
Size (byte): 12 176 391 487

Index: 3
Name: Windows Server 2012 SERVERDATACENTERCORE
Description: Windows Server 2012 SERVERDATACENTERCORE
Size (byte): 7,458,764,649

Postcode: 4
Name: Windows Server 2012 SERVERDATACENTER
Description: Windows Server 2012 SERVERDATACENTER
Size (byte): 12,171,118,256

Connecting a WIM image

We find in the list provided a suitable image by name, for example, "Windows Server 2012 SERVERSTANDARD", and mount it into the previously created empty directory "D: \ w2012":

dism /Mount-Wim /WimFile:"f:\Inst\Win2012\SW_DVD5_Win_Svr_Std_and_DataCtr_2012_64Bit_Russian_Core_MLF_X18-27640\sources\install.wim" /name:"Windows Server 2012 SERVERSTANDARD" /MountDir:D:\w2012

Now you can just copy the necessary files from this directory.

Disabling the WIM image

We will mothball our image:

dism /Unmount-Wim /MountDir:D:\w2012 /discard

Now you can just copy the necessary files from this directory.

Where:

  • / discard instructs you to undo all changes made.