To create bootable Windows PE UFD media
1. | Insert your bootable UFD device into an available USB port on your system.
|
2. | Use the DiskPart utility to prepare the device for loading Windows PE. To run DiskPart, type diskpart at the command prompt and then press ENTER.
|
3. | Run the commands shown in Table 1 to prepare the UFD.
Table 1. Preparing a UFD for Windows PECommand | Description |
---|
list disk | Lists available disks. | select disk n | Where n
is the UFD you are preparing.
Be sure to select the correct disk when using DiskPart.
DiskPart will clean your primary hard disk as easily as it will clean
your UFD device. | clean | Removes the current partition structures. | create partition primary size=size | size is the size of the disk as shown in the list. If you omit size, DiskPart will use all of the available space for the partition. | select partition 1 | Selects the partition you created in the previous command. | active | Marks the new partition as active. | format fs=FAT32 | Formats the UFD partition with the FAT32 file system. | assign | Assigns the next available drive letter to your UFD. | exit | Quits DiskPart. |
|
4. | Use the Bootsect.exe command to write a new boot sector to the UFD, where e: is the drive letter assigned to the UFD device:
Bootsect /nt60 e: /force
|
5. | Copy the contents of the ISO folder to your UFD, where e:\ is the drive letter assigned to the UFD device:
xcopy /chery c:\winpe_x86\ISO\*.* e:\
|
6. | Safely remove your UFD.
|
Note
Some UFD devices do not
support this preparation process. If necessary, use the UFD device
manufacturer’s processes and utilities to make the disk bootable. Once
you’ve done this, proceed from step 4 to prepare the device. |
Creating a bootable UFD requires careful
work. Many UFDs are not bootable, and need to be converted before use.
They are shipped with a flag value set to cause Windows to detect them
as removable media devices rather than USB disk devices.
To make your UFD bootable, consult with the
device manufacturer to obtain directions or utilities that will convert
the device. Many manufacturers make these instructions available through
their product support systems. Ask specifically how to switch the
removable media flag. This action will cause Windows to detect the
device as a USB hard disk drive and will allow you to proceed with the
preparations for creating a bootable UFD.
|
Booting from a Hard Disk Drive
While it might seem strange to be booting
Windows PE from a hard-disk drive, you can do this to perform refresh
installations of Windows Vista. By loading Windows PE onto the hard disk
and booting it to RAM, you can repartition your systems disks and
install the new Windows Vista
image. You can also use Windows PE as the basis for the Windows
Recovery Environment (Windows RE) to recover unbootable systems.
To boot Windows PE from a hard-disk drive
1. | Boot your computer from prepared Windows PE media.
|
2. | Using DiskPart, prepare the computer’s hard disk for installation of Windows PE. Use the DiskPart commands shown in Table 2.
Table 2. Preparing a Hard Drive for Windows PECommand | Description |
---|
select disk 0 | 0 is the primary hard-disk drive. | clean | Removes the current partition structures. | create partition primary size=size | size is a partition size large enough to hold the Windows PE source files. | select partition 1 | Select the partition created by the previous command. | active | Marks the new partition as active. | format | Formats the new partition. | exit | Quits DiskPart. |
|
3. | Make your hard disk bootable:
bootsect /nt60 c:
|
4. | Copy the Windows PE files from your Windows PE media to your hard disk:
xcopy /chery x:\*.* c:\
|
Customizing Windows PE
Most Windows PE customization tasks will involve
the processes described in the previous section. You will import and
install additional components, add applications, import and install
updates, and prepare and capture the resulting image.
Other tasks you might see when customizing your
Windows PE implementation include adding hardware-specific device
drivers and customizing the actual settings used by Windows PE when it
runs. This section covers the installation of device drivers and details
changes that you can make to base Windows PE configuration settings.
Windows PE supports four configuration files to
control startup and operation. These files can be configured to launch
custom shell environments or execute specified actions:
BCD
The Boot Configuration Data (BCD) file stores the boot settings for
Windows PE. This file is edited with the Windows Vista command-line
tool, BCDEdit.
Winpeshl.ini During
startup, you can start custom shell environments using the Winpeshl.ini
file. This file is located in the %SYSTEMROOT%\System32 folder of the
Windows PE image. You can configure this file with the path and the
executable name of the custom shell application.
Startnet.cmd
Windows PE uses the Startnet.cmd file to configure network startup
activities. By default, the Wpeinit command is called to initialize Plug
and Play devices and start the network connection. You can also add
other commands to this script to customize activities during startup.
Unattend.xml
Windows PE operates in the windowsPE setup configuration pass of a
Windows Vista installation. In this pass, Windows PE uses the
appropriate sections of the Unattend.xml file to control its actions.
Windows PE looks in the root of the boot device for this file. You can
also specify its location by using the Startnet.cmd script or by using
Wpeutil.exe with the appropriate command-line options.
Your final environment can run custom application shells (Figure 2).