0% found this document useful (0 votes)
195 views24 pages

Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) - Part 2 - Final Thoughts From IT PDF

This document describes how to create customized Windows 8.1 installation media using a WIM file to replace the default installation files. It involves using Hyper-V to build and customize a Windows 8.1 virtual machine, capturing it as a WIM file, and replacing the default install.wim file on installation media (ISO or flash drive) with the custom WIM file. Creating a UEFI bootable ISO or using two flash drives with the Microsoft Deployment Toolkit allows installation from larger custom WIM files that exceed 4GB size limits of single FAT32 partitions.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
195 views24 pages

Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) - Part 2 - Final Thoughts From IT PDF

This document describes how to create customized Windows 8.1 installation media using a WIM file to replace the default installation files. It involves using Hyper-V to build and customize a Windows 8.1 virtual machine, capturing it as a WIM file, and replacing the default install.wim file on installation media (ISO or flash drive) with the custom WIM file. Creating a UEFI bootable ISO or using two flash drives with the Microsoft Deployment Toolkit allows installation from larger custom WIM files that exceed 4GB size limits of single FAT32 partitions.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 24

Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

FINAL THOUGHTS FROM IT


Tips, Tricks & Hacks for the Enterprise IT Administrator

J A N U A R Y 1 6 , 2 0 1 5 B Y E C H O R E L AY

Creating Customized Windows 8.1 Media


(ISO, WIM, Flash Drive) | Part 2
In Part 1 we used Hyper-V to build, update, and sysprep our custom Windows 8.1
Installation. Now we need to make some Install media!

If you’re unfamiliar with this process, or you haven’t built customized Windows media

1 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

since the XP days, you may not be familiar with WIM �les. Essentially, the WIM �le is a
compressed image which is deployed during Windows installation. (Think of it like
extracting a large .ZIP �le.) If you take a look at your Windows 8.1 install media, you’ll
�nd that amongst the plethora of �les, the largest will be \Sources\install.wim –
approximately 3.1 GB on x64 media.

The last step you completed in Part 1 was creating a second Checkpoint (named
Complete). I’ll explain why, next.

Creating a WIM �le


As mentioned above, the install.wim �le is the actual source used when installing
Windows 8.1. Thus, we need to create our own WIM �le, and replace the stock one with
it. To do this, we need to “capture” the last Checkpoint.

On your host (physical machine), open up Disk Management.


WIN+X > Disk Management

2 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Navigate to Action > Attach VHD

Click Browse

Navigate to the directory where the virtual disks are stored for stage01.
By default this directory is: C:\Users\Public\Documents\Hyper-V\Virtual hard
disks/
In the bottom right, change Virtual Disk files (* .vhd, * .vhdx) to All files (* .
*)

Select the �le with the most recent Date Modi�ed – this is your Complete Checkpoint!

3 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Click Open
Check box Read Only and then click OK.

At this point you will see one new disk with two partitions. Make note of the second
partition drive letter (in my case, the F: Drive).

4 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Open the Command Prompt with Administrator Rights.


WIN+X > Command Prompt (Admin)

Type dism /capture-image /imagefile:c:\customInstall.wim /capturedir:F:\


/name:"Windows 8.1 Enterprise - Customized by: Joe Wright" /Description:"Windows
8.1 Enterprise - Customized by: Joe Wright" /compress:maximum /checkintegrity
/verify /bootable – replacing F: with the second partition drive letter you made note of
earlier – and replacing “Customized by: Joe Wright” with whatever you want.

5 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Depending on your processing power, this may take a little while. When complete, you
will see “This operation completed successfully.” You should now see a �le named
“customInstall.wim” at the root of your C:\ Drive.

Once con�rmed, head back into Disk Management and right-click the Read-Only VHD
disk and click Detach VHD. Click OK when prompted to con�rm.

Build the Customized Media


Double click the stock ISO you used to install Windows in stage01 to mount it within
File Explorer.
Open This PC and double click the newly mounted drive.
(In my case, Drive E: IR3_CENA_X64FREV_EN-US_DV9)
CTRL+A (to select all) and CTRL+C (to copy)

6 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Create a new folder named WinExtract off your C:\ drive


(Another location is �ne too, but these instructions will be assuming C:\)
Navigate to C:\WinExtract\ and CTRL+V (to paste).

After the copy completes, navigate to C:\WinExtract\sources\ and delete the


install.wim �le.

Move C:\customInstall.wim (your custom WIM) to C:\WinExtract\sources\.


Rename C:\WinExtract\sources\customInstall.wim to install.wim.

7 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

At this point, you are ready to create your ISO.

Create UEFI Bootable ISO


Open Command Prompt (Admin)
Change Directory to: C:\Program Files (x86)\Windows Kits\8.1\Assessment and
Deployment Kit\Deployment Tools\amd64\Oscdimg\
Run oscdimg -m -o -u2 -lIR3_CENA_X64FREV_EN-US_DV9 -udfver102
-bootdata:2#p0,e,bC:\WinExtract\boot\etfsboot.com#pEF,e,bC:\WinExtract
\efi\microsoft\boot\efisys.bin C:\WinExtract\
C:\en_windows_8.1_enterprise_with_update_x64_dvd_CUSTOM.iso

8 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Once complete, you now have a UEFI bootable ISO named


en_windows_8.1_enterprise_with_update_x64_dvd_CUSTOM.iso located at the
root of your C:\ Drive!

You can test to make sure it works by creating another Virtual Machine within Hyper-V
and choosing Generation 2 (UEFI bootable).

Make UEFI Bootable USB Disk


If you’ve ever needed to create a UEFI bootable USB disk before, you may be familiar
with the (brilliant) product named Rufus. It’s a very straightforward Windows ISO to
USB tool which, right off the bat, asks if you want to do a GPT partition (UEFI bootable)
or a MBR partition (BIOS bootable) drive.

9 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

There is only one problem with Rufus – we can’t use it when our new ISO contains a
WIM �le that is larger than 4 GB!

UEFI / GPT bootable drives require one of two con�gurations:

The entire drive be formatted as one large FAT32 partition.This is how most
flash drives are formatted.

The drive have a FAT32 formatted partition (with EFI boot �les) and another
(possibly NTFS formatted) partition.
This is how a UEFI Windows Installation is typically formatted.

Unless you have one of the new (pretty expensive) �ash drives that report to your
machine as an external hard drive (Fixed Disk), (or you’re using an external hard drive for
that matter) neither of these solutions will work for us. This is because FAT32 partitions
cannot contain a single �le larger than 4 GB and “normal” �ash drives cannot have more
than one partition.

So how do we install our Custom Windows 8.1 Media via a �ash drive?
Use two �ash drives – with the help of the Microsoft Deployment Toolkit.

Double-Click C:\en_windows_8.1_enterprise_with_update_x64_dvd_CUSTOM.iso to mount


your custom ISO. Make note of the drive letter assigned.
In my case, the drive letter is E:\
Open Deployment Workbench
Navigate to Deployment Shares and click New Deployment Share.

10 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Accept the defaults (Click Next 5x) and then click Finish.

Navigate to the Operating Systems section and click Import Operating System.

11 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Select Full set of source �les and click Next.

For the Source directory, click Browse and navigate to the drive letter you made
note of earlier.
(E:\ in my case.)

Click OK, then click Next.


Pick a name (or keep the default) and click Next twice to execute the action.

12 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Navigate to the Task Sequences section and click New Task Sequence

For the Task Sequence ID enter: 1


For the Task Sequence Name enter: Install OS

Click Next
Choose Standard Client Task Sequence as the sequence template.

Select the OS name you imported earlier.


(Mine is named Windows 8.1 Enterprise).

13 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Click Next 3x
Select the Do not specify an Administrator password at this time option and click
Next 2x.

Click Finish
Navigate to the Advanced Con�guration > Media section and click New Media.

Click Browse and navigate to the C:\ drive.


Click Make New Folder and name it “Media” > Click OK.

14 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Ensure Selection pro�le is set to Everything and click Next twice.

Once complete, click Finish.


Right-click the new entry named MEDIA001 and click Update Media Content.

15 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

The previous steps are a quick and dirty walk through of adding your
customized ISO into the Deployment Workbench and generating MDT Media.
Why we did this will be covered next. If you would prefer, there are many
additional customizations that can be accomplished here, however I am not
going to cover them in this article.

As established above, the secret to booting our customized media is by utilizing two
USB drives. This is why we installed MDT and went through the steps of generating
MDT media – MDT allows a “boot” drive (with UEFI support) and a secondary “deploy”
drive. Let’s prepare those now.

Gather two USB drives and plug them into your host.
The BOOT drive can be a 1GB drive.
The DEPLOY drive must be large enough to �t your WIM + about 1.2 GB.
Using our math skills, that would mean a 4 GB WIM + 1.2 GB = 5.2 GB. AKA:
we'll need at least a 6 GB flash drive (If such a size exists).
Format the BOOT drive as FAT32 and label the volume as BOOT.
Format the DEPLOY drive as NTFS and label the volume as DEPLOY.

16 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Now we’re ready to start copying data to the drives. Open an Explorer window and
navigate to C:\Media\Content\.

Perform the following steps for the BOOT drive:


Copy the C:\Media\Content\Boot\ folder to the root of the BOOT drive.
Copy the C:\Media\Content\EFI\ folder to the root of the BOOT drive.
Copy the following �les to the root of the BOOT drive:
C:\Media\Content\autorun.inf
C:\Media\Content\bootmgr
C:\Media\Content\bootmgr.efi

17 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Create a new folder named Deploy at the root of the BOOT drive.

Copy the C:\Media\Content\Deploy\Boot\ folder to the Deploy folder on the BOOT


drive (the folder you just created).

Perform the following steps for the DEPLOY drive:


Copy the C:\Media\Content\Deploy\ folder to the root of the DEPLOY drive.

18 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Safely remove both USB drives and you are ready for deployment!

Deploy Windows via Flash Drive


To deploy, plug both drives into your target machine and UEFI boot to the BOOT drive.

19 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Click Run the Deployment Wizard to install a new Operating System.

Select Install Windows 8.1 Enterprise (or whatever you named your WIM) and click
Next.

20 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

Follow the prompts to name the computer, join to domain (if desired), move user data
(if desired), set Administrator Password, etc.
Click Begin to initiate deployment.

Wait patiently as your customized Windows 8.1 Media is deployed to your machine,
utilizing UEFI.

Congratulations! At this point, you’ve successfully accomplished a task that drives


many admins crazy! Now get up, walk around, and maybe even get some fresh air. You
deserve it.

Additional Thoughts: I realize that splitting WIM �les would have sped up

21 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

this process considerably. Additionally, it would have completely negated the


need to use a second �ash drive or even install MDT at all. Unfortunately, for
some reason, Microsoft decided to remove split WIM functionality from
Windows 8.1 – thus, I had to �nd another solution. The bene�t to this is that I
gained some MDT experience, and going forward I’m going to try and use it
for standalone scenarios where SCCM is not available.

Let me know your experience with following these steps! Hopefully they were relatively
easy to follow and you didn’t run into too many snags.

Until next time..

22 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

18 Comments Final Thoughts from IT 


1 Login

 Recommend 2 t Tw eet f Share Sort by Best

Join the discussion…

LOG IN W ITH
OR SIGN UP W ITH DISQUS ?

Name

Abdulla Ashoor • 10 months ago


could you please explain w hat is -lIR3_CENA_X64FREV_EN-US_DV9 exactly? is it custom?
w hat it used for and in case I change it w ill affect anything?
△ ▽ • Reply • Share ›

echorelay Mod > Abdulla Ashoor • 10 months ago


The "l" (low ercase L) is for label - how ever oscdimg doesn't require a space (thus
making for one very confusing command string).

"IR3_CENA_X64FREV_EN-US_DV9" is simply the drive label of the original ISO I


dow nloaded off MSDN. Microsoft used to change these labels w ith each version,
but it appears they've stayed the same for the last few releases. You can
technically put anything here you w ant - I just kept it the same as the original ISO.
△ ▽ • Reply • Share ›

JoVaRi • 2 y ears ago


When I try to use the image created w ith 'Oscdimg', right after booting and pressing "install
now " the setup tells me, that the product-key is not valid for the available w indow s images
and that I have to enter a different one.
When preparing the image, I never entered any product key. Do you have an idea?
(basically it's this problem, but I can't fix it because activation of the image w ill be done via
KMS) -
https://support.microsoft.c...
△ ▽ • Reply • Share ›

echorelay Mod > JoVaRi • 2 y ears ago


It sounds like you created a WIM for one edition but used install media from another
edition. Are you using Enterprise? If not, you need to delete the EI.CFG file from
w ithin the \Sources\ folder on the install media (before you create the ISO). Give
that a shot :)

If you're using Enterprise, you need the EI.CFG file w ith the contents:
[EditionID]
Enterprise

23 of 24 11/21/2018, 2:53 AM
Creating Customized Windows 8.1 Media (ISO, WIM, Flash Drive) | Part... https://finalthought.org/2015/01/16/creating-customized-windows-8-1-m...

24 of 24 11/21/2018, 2:53 AM

You might also like