Installing Windows to an EFI-Based Computer
If you are installing Windows to an EFI-based computer, you must enable EFI mode in the computer's firmware. You must enable EFI mode in both attended and unattended installations. You must boot to 64-bit EFI-mode preinstallation media (64-bit Windows PE in EFI mode, or 64-bit Windows Setup in EFI mode). You cannot install Windows to UEFI-based computers in BIOS mode. (For more information about switching modes, see your EFI firmware documentation.) The steps described in this topic are for reference only and may not match the specific commands for your EFI firmware type.
After Windows is installed, you can make additional configurations to your image. This Windows image becomes your master image that you use to deploy to other computers.
To Install Windows to an EFI-Based Computer
Install Windows by running Windows Setup from an EFI boot entry on the master computer. Use the EFI shell or the firmware’s “Boot from file” menu to launch the Windows EFI Boot Loader on the installation disk. Refer to your firmware documentation for more information.
From the EFI shell, select the device with the Windows installation media and start the EFI boot application. Assuming that the DVD device is fs0, use the following commands for x64-based computers:
Shell> Fs0: fs0:> \EFI\BOOT\BOOTX64.EFI
For the Itanium-based computers, use the following command:
If the EFI boot manager supports booting from a DVD, the EFI shell command is not required. You can boot the DVD directly from the EFI boot manager.
When prompted, press any key to boot from the Windows DVD. Windows installs to the computer.
If you perform an attended install, follow the user interface prompts to complete Windows Setup.
Optionally, you can perform an unattended installation by using an Autounattend.xml file stored on a USB disk on key or other device. For the answer file requirements for EFI-based computers, see Create an Answer File for UEFI-based Computers.
Some EFI platforms support both UEFI and BIOS firmware. On some of those systems, it is not always clear if the default DVD boot option is an EFI or BIOS boot option. On these systems, using the EFI shell command may be required. If you do not specifically start Windows Setup by using the EFI boot entry, the default firmware boot entry for BIOS may be used. If Windows Setup starts in BIOS mode on a combined EFI/BIOS system, the ESP and MSR partitions are not created. After Windows Setup completes, use the Diskpart command to verify that the ESP and MSR partitions were created.
After Windows is installed to the computer, complete all other customization tasks.
From an elevated command prompt, run sysprep to prepare the Windows image for imaging and deployment. For example,
%WINDIR%\system32\sysprep\sysprep.exe /generalize /oobe /shutdown
When the Sysprep command completes, the computer shuts down.
Capture the Windows Image
After the Windows image is installed, you can capture the Windows image and the EFI partition image to deploy to other computers.
Create a network share where you intend to copy your master Windows image and ESP image to. For example,
net use n: \\MyNetworkShare\Images
Assign a drive letter to the ESP by using the diskpart command. For example,
diskpart select disk 0 //Select the first disk select partition 1 //Select the ESP volume to configure assign letter=s //Assign drive letter s to the ESP exit
Capture the ESP by using ImageX. For example,
imagex /capture s: n:\efisys.wim "ESP"
Capture the Windows image by using ImageX. For example,
imagex /capture c: n:\OSimage.wim "Windows"
The images are ready to be applied. For more information, see Apply a Windows Image to UEFI-based Computers.