One of the most popular tools to migrate user profiles from one Windows computer to another is the set of CLI utilities – User State Migration Tool (USMT), which is a part of the Windows Assessment and Deployment Kit. USMT tool allows you to automate and simplify the process of migrating the users’ environment and profiles while deploying Windows and in other cases.
The transfer of user data takes place in two steps, one of which takes place on the old one and the other one on the new computer. USMT can migrate operating system settings, applications, and even access control lists (ACLs). This means that the user’s access permissions on the target computer will be the same as they were on the source system.
Migrating User Profiles using USMT
The latest currently available version of USMT 10 allows you to migrate user settings and profiles and apply settings from operating systems starting from Windows 7 and up to Windows 10. The important difference from the previous version of this utility is the ability to collect the settings in Offline mode (not while running the operating system). If you want to use USMT on older systems (Windows XP, Windows Vista), then you must use version USMT 3.0.1.
You can download the ADK for Windows 10 here.
To install ADK on your admin’s workstation or on the source computer, run adksetup.exe file and select User State Migration Tool (USMT) to install:
After the installation is complete, you can find the USMT files in the directory C:\Program Files (x86)\Windows Kits\10\Assessment and Deployment Kit\User State Migration Tool (later you can copy these files to the source computer).
This utility consists of two console programs scanstate.exe and loadstate.exe, as well as a set of XML files describing the process of collecting and applying settings.
Data transfer using USMT can be performed in two steps: exporting data from the source computer using the ScanState command and importing data on the target computer using the LoadState.
USMT allows you to write data to a local disk, removable USB drive, or a network share, but cannot transfer data across the network directly from the source to the target computer.
Saving a User Profile with USMT
The first stage of the transfer takes place on the source (old) computer. To collect user data, the scanstate command is used.
Scanstate.exe scans the computer according to the specified requirements, creates a repository, and collects user profiles and accounts, application and OS settings, files, registry keys, and other data.
Note. From Windows 10 1607, USMT can’t migrate the start menu layout. Instead you must use Export-StartLayout and Import-StartLayout cmdlets.
The USMT utility creates 4 migration files (in .XML format) that store rules for migrating various kinds of data:
- MigApp.xml — contains rules for transferring user data;
- MigUser.xml — contains rules for transferring user profiles;
- MigDocs.xml — document transfer rules;
- Config.xml — covers information on the components that are excluded from the transfer.
To migrate all accounts and user settings from one computer to another, run the command:
scanstate \\fs1\migr\userdata /i:miguser.xml /i:migapp.xml /o
To migrate only two user accounts from one computer to another:
scanstate \\fs1\migr\userdata /ue:** /ui:corpuser1 /ui:corpuser2 /i:miguser.xml /i:migapp.xml /o
For example, to create encrypted store (with an encryption key – StR0n51) on a network shared folder using specified configuration files, you can use the following command:
scanstate \\fs1\migr\mystore1 /i:migapp.xml /i:miguser.xml /o /config:config.xml /encrypt /key:"StR0n51"
Also, you can use USMT to perform offline profile migration. Boot your system into the Windows РЕ environment and run the ScanState to export user’s profiles settings.
Another interesting way to use the USMT is to perform a backup of user profiles on some critical computers.
Migrating and Deploying a User Profile with USMT
The second step of transferring the user profile is performed on the target (new) computer. To complete the migration, use the loadstate.exe command. The loadstate utility imports (unpacks) all store items to the target computer.
To load on source computer all profiles from store created earlier, run:
loadstate \\fs1\migr\userdata /i:miguser.xml /i:migapp.xml
If you want to transfer user’s profile and move a user from one domain to another:
loadstate \\fs1\migr\userdata /mu:/ui:corpuser:/ui:corp2user /i:miguser.xml /i:migapp.xml
For example, to load user profiles from encrypted store on a network shared run the command:
scanstate \\fs1\migr\mystore1 /i:migapp.xml /i:migapp.xml /i:miguser.xml /decrypt /key:"StR0n51"
- Using Process Monitor (ProcMon) to Track File and Registry Changes - October 23, 2020
- Fix: Unable to Find a Default Server with Active Directory Web Services Running - October 23, 2020
- How to Fix Windows 10 Flashing Screen? - October 20, 2020