Datasheet
Designing User State Migration
17
3. Type the following lines in the text document. Note that the ScanState and LoadState
commands span two lines in this book, but they should be entered as a single com-
mand in the document.
Cd “c:\Program Files\Windows AIK\Tools\USMT\x86”
rem
ScanState.exe c:\store /v:13 /o /c /hardlink /nocompress /efs:hardlink
/i:MigApp.xml /i:MigDocs.xml /offlineWinDir:c:\windows.old\windows
rem
LoadState.exe c:\store /v:13 /c /lac:P@ssw0rd /lae /i:MigApp.xml
/i:MigDocs.xml /sf /hardlink /nocompress
The first command changes the directory to the
...\USMT\x86 folder on the C:
drive. If you are running a 64-bit system, you can substitute this with
...\USMT\
amd64
instead. The rem lines are remark or comment lines I added to separate the
ScanState and LoadState commands for easier readability.
4. Select File Save As.
5. Type in usmt.bat and click Save. By adding the .bat extension, you tell Notepad to
save the file as a batch file (with a
.bat extension) that can be executed instead of a
text file (with a
.txt extension). Close the file.
6. Click Start Accessories, right-click the command prompt, and select Run As Admin-
istrator. If prompted by User Account Control, click Yes to continue.
7. Type in the following command to change the directory to the C:\MyUSMT directory
you created earlier:
Cd \MyUSMT
8.
Type in usmt and press Enter to run your batch file. This will take several minutes to
complete, and the output will appear on the screen. When you’ve finished, the migra-
tion is complete.
9. Using Windows Explorer, browse to the C:\Program Files\Windows AIK\Tools\
USMT\x86
folder (or the C:\Program Files\Windows AIK\Tools\USMT\amd64 if you
used that folder in your batch file. Locate and open the
loadstate.log file and the
scanstate.log file. With a verbosity level of 13 used in the commands, you’ll see
that a lot of data has been logged and can be reviewed to view the activity of both
commands.
EXERCISE 1.3 (continued)
597095c01.indd 17 6/2/10 4:12:57 PM