Using Windows PE 2.0 and Image X to deploy Windows XP Embedded
Goals
-
Create a customized Windows PE 2.0 (Vista PE) environment.
-
Create a WIM file of pre-FBA files create by Target Designer.
-
Boot to Windows PE 2.0 to deploy a new runtime image using ImageX.
Create a customized Windows PE 2.0 environment.
Install and configure the Windows Automated Installation Kit
1. Install the Windows Automated Installation Kit using the defaults for all setup options.
2. Create the default Windows PE environment using the Windows Automated Installation Kit. On the development workstation run copype.cmd to create a new PE environment (first time setup). Copype.cmd is located in c:\Program Files\Windows AIK\Tools\PETools. You need to specify the CPU architecture for the target device and the destination folder that will contain the PE files. From a command prompt type: “c:\ Program Files\Windows AIK\Tools\PETools\copype.cmd x86 c:\winpe_x86” to create the Windows PE output for any x86 platforms in the directory c:\winpe_x86.
3. Copy any additional support files that may be necessary to use into the Windows PE build directory. Since we will use ImageX to deploy the runtime image we need to include the necessary files in the configuration. Copy the imagex.exe utility to the ISO. Using Explorer copy c:\Program Files\Windows AIK\Tools\x86\imagex.exe to c:\winpe_x86\iso.
Create the initial runtime image to deploy
Using Target Designer, create a runtime image that includes the necessary components to support the target device. Resolve dependencies and build the runtime image. Choose Release as the Build type. Specify c:\winpe_x86\image as the Destination for the runtime image. Leave the Log file location as the default. The image will be copied to the staging location. In a later step we will use ImageX to create a WIM image file of the contents of this directory.
Create the WIM image to be included with the ISO
Using ImageX create a WIM image file that contains the pre-FBA contents generated by Target Designer. From a command prompt type: “c:\Program Files\Windows AIK\Tools\x86\imagex.exe /compress fast /capture c:\winpe_x86\image c:\winpe_x86\iso\xpe.wim “XPe” /verify”
Create the bootable ISO image
1. To create the bootable ISO, use the oscdimg.exe utility located in c:\Program Files\Windows AIK\Tools\PETools. From a command prompt type: “c:\Program Files\Windows AIK\Tools\PETools oscdimg -n -bc:\winpe_x86\etfsboot.com c:\winpe_x86\ISO c: \winpe_x86\winpe.iso” The new ISO named winpe.iso is saved in c:\winpe_x86. Create a CD or DVD from the ISO using your installed CD/DVD burning utility.
2. Insert the CD / DVD into the target system. Make sure the boot order in the BIOS of the system is set to boot from CD/DVD first.
Image the local disk on the device with the XP Embedded runtime image
1. From Windows PE use diskpart and format to prepare the local hard disk for the runtime image. From the command prompt in Windows PE type:
diskpart
select disk 0
clean
create partition primary size=1024
select partition 1
active
exit
format c: /fs:ntfs /y /v:XPe2.
Use ImageX to image the hard drive.
D:\imagex.exe /apply d:\xpe.wim 1 c:
Note: The partition size can be any size (in MB) within the limits of the physical hardware. If the size parameter is not specified diskpart will use the entire disk.
Note: When formatting the partition after creating it with diskpart, execute a full format. ImageX errors have been reported when imaging partitions that were quick formatted.