none
relocate your user folder to a different drive

    Question

  • Hi,

    I got the following procedure to move user data to different drive, the only thing that I am looking for is there any way to automate the process of hard link ofter the OS is restored?? I mean once the OS is restored then the old user data should be set /made availble automatically.

    Below is the procedure that I found to do it in a manual way.

    Steps for Moving the C:\User\YourUser to D:\User\YourUser :

    1. Install the OS, and create your user. We’ll call it ‘YourUser’
    2. Create a temp user (with administrative privileges). We’ll call it ‘TempUser’
    3. Login with TempUser account
    4. Make sure you configured your windows explorer to list hidden and system files (Folder options)
    5. Move (cut/paste) the entire C:\User\YourUser folder to a different drive, for example to D:\User\YourUser .
    6. Create a HardLink from C:\User\YourUser to D:\User\YourUser , so when the OS looks for C:\User\YourUser it will find it in D:\User\YourUser . To create this hard link, open the cmd window with administrator privileges
      image and type:
      mklinkC:\User\YourUser” “D:\Users\YourUser” /j 
      (make sure there is no C:\Users\YourUser folder before you create the link, and that you run the cmd.exe as administrator)
    7. Restart the computer and login as YourUser, and there you have it. Your entire user folder is located in D: drive.
    8. Remove the tempUser account.

    Steps for re-using your D:\User\YourUser folder, after re-installing the OS:

    1. Install the OS, and create your user. We’ll call it ‘YourUser’
    2. Create a temp user (with administrative privileges). We’ll call it ‘TempUser’
    3. Login with TempUser account
    4. Make sure you configured your windows explorer to list hidden and system files (Folder options)
    5. Browse to C:\User\YourUser (the newly created user folder), and copy all the hidden files which starts with ntuser* (should be 7 files
      image
    6. Paste these files to your old D:\User\YourUser (override the ones which resides there)
    7. Delete the C:\User\YourUser folder
    8. Create the hardlink as explained before.
    9. Configure YourUser to be the owner of the D:\User\YourUser folder:
      Right-Click ‘YourUse'r’ folder –> Properties –> Security –> Advanced –> Owner..
    10. Restart the computer and login as YourUser, and there you have it. Your entire user folder, located in D: drive, is now re-used.
    11. Remove the tempUser account.

    N.A.Malik
    Saturday, January 01, 2011 6:29 PM

Answers

  • Hi,

    If you want to consider this method to move your user profile, and make it automatically. It’s better to use a .bat file to achieve it.

    I suggest to post your thread at Scripting Forum for better help.

    You may also refer to the following link.

    http://www.starkeith.net/coredump/2009/05/18/how-to-move-your-windows-user-profile-to-another-drive/

    As the article says, there is “Microsoft Approved” method, you may consider this method.

    But I would like to advise that maybe have some potential issue after moving the profiles.


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. ”
    Tuesday, January 04, 2011 9:02 AM
    Moderator

All replies

  • Hi,

    If you want to consider this method to move your user profile, and make it automatically. It’s better to use a .bat file to achieve it.

    I suggest to post your thread at Scripting Forum for better help.

    You may also refer to the following link.

    http://www.starkeith.net/coredump/2009/05/18/how-to-move-your-windows-user-profile-to-another-drive/

    As the article says, there is “Microsoft Approved” method, you may consider this method.

    But I would like to advise that maybe have some potential issue after moving the profiles.


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. ”
    Tuesday, January 04, 2011 9:02 AM
    Moderator
  • Hi,

    Thank you for the reply. Do you think in Unattend Answer file with settings of PROGRAMDATA and USERPROFILE SETTINGS is good approach to achive my goal?


    N.A.Malik
    Tuesday, January 04, 2011 7:56 PM
  • Hi,

    Yes, you may try it, I will give you some article for your reference as follows:

    http://technet.microsoft.com/en-us/library/cc730695(WS.10).aspx 

    In addition, You can use this method to run Script to achieve your purpose.


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. ”
    Wednesday, January 05, 2011 3:03 AM
    Moderator
  • I tried that method, User Data and Program data I directed into E:\ drive and when I run the OS after Sysprep/generalize ...I was not able to login,says user cannot login due user profile.

    Any ideas?


    N.A.Malik
    Wednesday, January 26, 2011 9:26 PM
  • This process is great for the start and using the MKLINK command was much easier than some of the other stuff I was reading, you just have to search the REGEDIT after to change all of the references to the new drive letter (i.e. C:\USERS\YOURACCOUNT  to D:\USERS\YOURACCOUNT).  In REGEDIT just start at the top and click EDIT then FIND (or ctrl f) and type C:\USERS\YOURACCOUNT and when it finds one change it to the correct drive letter then hit [F3] to the search to continue.  Once you've change them all, do this for each user account you want to move to the new drive or partition and restart.  I just did it on my new system and worked perfectly.
    Friday, January 11, 2013 2:19 AM