Finally figured out how to move a Windows user to another directory. I like to do this so the data remains the same when I have to reformat the c: drive because Windows has bombed once again.
Microsoft never thinks about placing users files on separate partitions and/or drives, so they make it difficult, but it can be done. NOTE: I have a systemrescuecd (Linux based, see http://www.sysresccd.org/) that I use at one point, however you can also use robocopy and a remove instead. It is just cleaner with a Linux mv command. If you have not used systemrescuecd, you should try it out as it really helps recover Windows issues sometimes.
- Create the user, then log in as the user. This will create the users data files under c:\users\username. Do not do anything else to the user at this point.
- Move the users files to the new location. I'll assume you are putting it on d:\Users, though it can be anyplace.
- With SystemRescueCD
- reboot into SystemResuceCD
- mount the c: drive and the d: drive in two locations under /mnt (SystemRescueCD requires it not be mounted on /mnt, but under a subdirectory). I'm using /mnt/windows for c: and /mnt/backup for d:
- Move the files with
mv /mnt/windows/Users/username /mnt/backup/Users
- Reboot back into Windoze
- Log in as a system administrator (not the user you are fixing)
- open a command prompt as administrator, ie find the command prompt icon, right click, select Run As Administrator
- Without SystemRescueCD
- Log in as a user with administrative user (not the user you are fixing)
- open a command prompt as administrator, ie find the command prompt icon, right click, select Run As Administrator
cd c:\Users
robocopy /MIR c:\Users\username d:\Users
del /s /q c:\Users\username
- Create a link c:\Users\username pointing to d:\Users\username,
mklink /J c:\Users/username d:\Users\username
Note: the command is "backwards" as far as I'm concerned; the name of the link is first, and the target is second. - Log out and log in as the user. All should work as normal.
- http://answers.microsoft.com/en-us/windows/forum/windows_7-files/how-do-i-move-my-users-folder-to-a-different/83a1aa8e-1851-479e-8ec4-61801be2cf83
- http://answers.microsoft.com/en-us/windows/forum/windows_7-files/offline-files-save-to-alternate-partition/6af0cf60-84f6-4e48-b0a1-2780a5fd7b7a
- http://answers.microsoft.com/en-us/windows/forum/windows_7-files/is-it-safe-to-modify-userprofile-what-are-the/bb84d104-d6d6-43c5-be62-b065ee4fa819
- http://answers.microsoft.com/en-us/windows/forum/windows_7-files/how-can-i-move-default-location-of-public-folders/924138a5-bdb2-4ab4-870b-57b3a8b8ff44
- http://answers.microsoft.com/en-us/windows/forum/windows_7-files/how-do-i-place-user-directories-on-a-separate/8d15f660-293a-48cc-bfc3-f978ad59d67e