The second scenario will involve the creation of a master image file, deployment point to host the image file and any additional applications to be added during installation, and the creation of an automated PE boot disk to contact the share and load the operating system image file.
This example would be of use for larger deployments, requiring additional applications, with high bandwidth network connections.
Foundation
Download and install VM Ware Workstation on a machine with at least 2 GB of RAM and 80 GB of available disk space, running Windows XP or 2000.
Build an initial virtual workstation (VM1) using either Windows XP, Vista, or Windows 2003 Server. VM1 will need 512 MB of RAM, 30 GB of disk space, with CD-ROM and floppy devices attached. Install VM Ware Tools.
Download and Install the Windows Advanced Installation Kit on VM1.
Building a Custom PE Boot Disk
- From VM1, open a command-line window and run Copype.cmd to create a local Windows PE build directory:
- Cd Program Files\Windows AIK\Tools\PETools\
- Copype.cmd arch destination where arch can be x86, amd64,or ia64 and destination is a path to a local directory, for example, type:
- Copype.cmd x86 C:\WinPE_x86
- Copy additional tools such as ImageX into your Windows PE build directory. For example, type:
- Copy “C:\Program files\Windows AIK\Tools\x86\imagex.exe” C:\WinPE_x86\iso\subfolder
- Where subfolder is any folder structure required to support your tools.
- Using Notepad or any text editor, create the following configuration file, and then save it with the name wimscript.ini:
- [ExclusionList]
ntfs.log
hiberfil.sys
pagefile.sys
"System Volume Information"
RECYCLER
Windows\CSC
[CompressionExclusionList]
*.mp3
*.zip
*.cab
\WINDOWS\inf\*.pnf
Note: This configuration file instructs ImageX to exclude certain files during the capture operation you will do in the next step.
- ImageX automatically detects wimscript.ini if it is located in the same location.
- Save the configuration file to the same location as Imagex as specified in the previous step. For example:
- C:\WinPE_x86\iso\subfolder
- To save the captured image to a network share, the VM Ware network drivers must be included in the PE iso image.
- Start by mounting the WIM image file:
- imagex /mountrw c:\winpe_x86\winpe.wim 1 c:\winpe_x86\mount
- Add the drivers to the image file, assuming the drivers are in the "C:\Program Files\VMware\VMware Tools\Drivers\vmxnet” location:
- peimg /inf="C:\Program Files\VMware\VMware Tools\Drivers\vmxnet\vmxnet.inf" c:\winpe_x86\mount\windows
peimg /inf="C:\Program Files\VMware\VMware Tools\Drivers\vmxnet\vmware-nic.inf" c:\winpe_x86\mount\windows
- Copy the inf files to the \inf folder under the \windows directory
- copy "C:\Program Files\VMware\VMware Tools\Drivers\vmxnet\vmxnet.inf" c:\winpe_x86\mount\windows\inf
copy "C:\Program Files\VMware\VMware Tools\Drivers\vmxnet\vmware-nic.inf" c:\winpe_x86\mount\windows\inf
- Finalize the changes in the PE image file:
- peimg /prep /f c:\winpe_x86\mount\Windows
- Commit the changes and dismount the image file:
- imagex /unmount /commit c:\winpe_x86\mount
- Create an image file (.iso) by using the Oscdimg tool. To do this, type:
- Oscdimg c:\winpe_x86\ISO c:\winpe_x86\winpe_x86.iso -n bc:\winpe_x86\etfsboot.com
- Burn the image (Winpe.iso) onto the blank CD-ROM, or copy it to the host workstation and mount it with an ISO emulation tool. You now have a Windows PE CD with ImageX.
Note: This link is to an example batch file. It will perform the steps listed above.
Preparing the Workstation for Image Capture
- Build a workstation, either manually, or using an unattend.xml answer file.
- Install additional applications, e.g. Office and VM Ware tools.
- Prepare the workstation by removing all machine specific settings:
- c:\windows\system32\sysprep\sysprep.exe /oobe /generalize /shutdown
Capture the Image File and transfer it to the Network
- Boot from the PE boot disk
- At the PE prompt, type:
- d:\tools\imagex.exe /compress fast /capture c: c:\custom.wim "my Vista Install" /verify
- Copy the image to a network location. If the environment is VM Ware, the drivers will have been included on the PE Boot disk by the earlier stages. Connect to a network share and copy the image file from the C: drive to the share point.
Manual Deployment of a Custom Vista Image File from A Network Share
Once an image file has been captured and stored on a network share point, applying the image to a new workstation is very similar to the capture process. The workstation is booted from the Windows PE CD, created in the previous section, and ImageX is used to apply the image file to the local hard drive.
Two additional points to note are; if a partition does not exist on the new workstation, one must be created (and of the same size as defined in the answer file Autoinstall.xml), and secondly, copying the image file locally before applying it will greatly enhance performance and reduce network traffic.
- On the destination computer, boot from the PE disk and launch a command-prompt window.
Note If this machine has been used for testing already, the hard drive contains an active partition. Override the boot order to boot from the CD/DVD-ROM drive.
- Format the hard drive to reflect the required disk configuration requirements by using DiskPart. Even if the machine has a viable partition, it is still necessary to format the drive. From a command prompt, type:
- diskpart
select disk 0
clean
create partition primary size=20000
select partition 1
active
format
exit
Note You can script this information by saving this information to a text file and storing it in the same location as your image. To run the script from a Windows PE command prompt, type diskpart /s scriptname.txt
- Copy the image from the network share to your local hard drive. For example, from the command prompt, type:
- Apply the image to the hard drive using ImageX located on your Windows PE media. For example, from the command-prompt window, type:
- d:\custom\imagex.exe /apply c:\custom.wim 1 c:
- Boot the machine and verify the successful application of the image.
Too much?
Need help?
Call C3SC at +1 866 799 2969 - Now!