Datasheet

18
Chapter 1
Planning for the Installation of Windows 7
While the previous exercise had you create a batch file with the ScanState and
LoadState commands, it is possible just to execute the commands at the command prompt.
However, if you have created the batch file, you can create your own portable tool that can
be easily executed on any system to perform an in-place migration.
Creating a Portable USMT Batch File
If desired, you can make your batch file a little more portable. Instead of installing the
Windows AIK for Windows 7 on every computer that you are migrating, you can copy the
appropriate files to a USB flash drive or CD. These files consume only about 50 MB.
You can then bring your USB flash drive or CD to any computer that has had an in-place
migration, run the batch file, and the migration will be done in minutes.
For more on this process, check out the TechNet article “Building a USB
Drive to Store USMT 4.0 Files and Simple Commands.” You can read it
here:
http://technet.microsoft.com/library/dd940094.aspx.
You’ll still need to install the Windows AIK onto a Windows 7 computer. Once it’s
installed on any Windows 7 computer, you can use Windows Explorer to copy the
USMT
folder onto the portable media such as a USB flash drive.
Browse to the
C:\Program Files\Windows AIK\Tools\USMT folder.
Right-click the
USMT folder and select Copy.
Insert a USB flash drive.
Browse to the USB flash drive using Windows Explorer, right-click, and select Paste.
At this point, you’ll have the entire contents of the USMT folder on the flash drive. This
includes the
USMT folder used for 64-bit systems (\USMT\amd64\) and the folder used for
32-bit systems (
\USMT\x86).
Now you’ll need to create a batch file that can be used on any system. The batch file
used in the previous exercise can be used as a starting point, but it will need to be slightly
modified.
The USMT files need to be copied to the C: drive on the system that is being migrated,
so the first step in the batch file is to copy these files. This sounds simple enough, but
it’s impossible to tell what the letter of the USB drive will be when it’s plugged in on any
given system. That is, when you plug the USB into Sallys computer, the USB disk may be
assigned the letter E:, but when you plug it into Joe’s computer, it might be assigned the
letter F:.
You can use the following
If exist statement in the batch file to check to see if the
USB flash drive is assigned the letter D:. It checks for the
USMT folder at the root of D:. If it
exists, it assumes this is the USB flash drive and copies the
USMT folder from the flash drive
to the Windows folder on the C: drive.
If exist D:\USMT\*.* XCopy /e /v /y C:\Windows\USMT\
597095c01.indd 18 6/2/10 4:12:57 PM