Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: User Profiles - Create and Move During Windows 7 Installation

20 Feb 2013   #590
Kaktussoft

Microsoft Community Contributor Award Recipient

Microsoft Windows 7 Home Premium 64-bits 7601 Multiprocessor Free Service Pack 1
 
 

Quote   Quote: Originally Posted by Kari View Post
OK, I have tested a new, different scenario now on three PC's, and it works. Here's what you should do if installing Seven on SSD and relocating User folders using this method, or if for any reason wanting to move ProgramData and / or Users after Windows is already installed. This method can be used whenever you want to relocate Users to another disk on an existing installation of Seven.

If you want to install Seven on an SSD: Install Seven normally to SSD, disconnecting all other disks. After Windows has booted first time normally after installation, shut the computer down and reconnect other disks. Reboot Windows.

Relocating Users and ProgramData folders when Windows Seven is already installed:

Run Command Prompt as administrator by clicking Start Menu > All Programs > Accessories, then right clicking Command Prompt and selecting Run as Administrator:

Attachment 128354

Type this to command prompt: C:\Windows\System32\Sysprep\Sysprep.exe /audit /reboot, hit Enter.

Attachment 128355

Windows reboots now to Audit Mode, "thinking" it's been started first time as the message on screen shows:

Attachment 128356

Now continue from beginning of page 4 in tutorial, and follow the steps described. Running the script causes Windows to move ProgramData and Users folders from C: to another disk or partition, also moving all content of said folders. The later you do this, the longer it takes because Windows has more to move.

Notice that this really makes Windows think it's first boot, so you have to select country and keyboard layout and again create a user account when first time booted in OOBE (normal) mode after running the script. Because the Users folder already contains your user account folders, you get an error message if trying to input the same name:

Attachment 128342

Use a temporary name, for instance Test to continue first boot routine. When Windows stops for login, choose your old account to login, for instance in my case I chose here Kari and not the account Test which I just created:

Attachment 128343

When finally in Windows desktop, go to User Accounts and remove the unnecessary Test account. That account has yet no folders to remove because Windows does not create user folders when user account is created; the user folders are only created when user logs in first time.

That's it. Works without any problems whatsoever.

Kari
Does it really relocate all already made users? So for example C:\users\myname will be transfer to D:\base\myname? All junction points will also be created in D:\base\myname ?
Some installed programs save some stuff like C:\users\myname\documents hardcoded in registry. Will this be fixed?

Or does it just create a junction from C:\USERS to D:\BASE and moving all stuff (also junctions) inside?
Just doubleclick on C:\USERS and check


My System SpecsSystem Spec
.
20 Feb 2013   #591
Kari

Microsoft Community Contributor Award Recipient

 

Yes, it transfers everything. The first OOBE boot after sysprep might take a long time, though, depending on how much user data there is to move (the move itself is not done when sysprepped, it's done during first OOBE boot).

All registry entries will be changed (current user, default user all users etc.), for this method changes the value of <ProfilesDirectory> variable completely, going through every instance of it in registry. It kind of hard codes the new value of this environment variable to the system. Each and every existing profile will be moved.

It does not create any junctions or links. It simply changes the default value of a Windows environment variable and acts thereafter as if this new value were the correct, default value. Drive_X:\Users will be the default value of <ProfilesDirectory> in every aspect, in a failproof way.

Kari
My System SpecsSystem Spec
20 Feb 2013   #592
Kaktussoft

Microsoft Community Contributor Award Recipient

Microsoft Windows 7 Home Premium 64-bits 7601 Multiprocessor Free Service Pack 1
 
 

Quote   Quote: Originally Posted by Kari View Post
Yes, it transfers everything. The first OOBE boot after sysprep might take a long time, though, depending on how much user data there is to move (the move itself is not done when sysprepped, it's done during first OOBE boot).

All registry entries will be changed, for this method changes the value of <ProfilesDirectory> variable completely, going through every instance of it in registry. It kind of hard codes the new value of this environment variable to the system.

It does not create any junctions or links. It simply changes the default value of a Windows environment variable and acts thereafter as if this new value were the correct, default value. Drive_X:\Users will be the default value of <ProfilesDirectory> in every aspect, in a failproof way.

Kari
So it does sort of search and replace on ALL user registry files. But does it do the same thing on ini files and for example settings.dat in appdata? Many programs save their settings in appdata in files like settings.dat, perferences.cfg etc.
My System SpecsSystem Spec
20 Feb 2013   #593
Kari

Microsoft Community Contributor Award Recipient

 

Yes. Everything.

Create a test machine on VirtualBox or VMware and see it yourself. When the variable value is changed, everything that was previously pointed at C:\Users will now be pointing to X:\Users.

Not many days ago I showed a neighbor how to do this. Over 80 gigs of user data on two accounts, Ms Office, VLC and a few more players, PhotoShop, Windows Live apps, bunch of games and other installed apps. Took almost an hour, everything works.

Kari
My System SpecsSystem Spec
.

20 Feb 2013   #594
Britton30
Microsoft MVP

Windows 7 Ultimate X64 SP1
 
 

Kaktussoft yes it is all truly moved and it is one system spread over two drives. Even new accounts will be created on the secondary drive. when you click, say Documents, from the Start menu it will open without you even knowing Documents is on another drive. Nice slick way to do it. Even the Desktop folder is moved since it is in the Users folder.

My hang up was predicting how windows would assign drive letters for the script.
My System SpecsSystem Spec
25 Feb 2013   #595
FredyC

Windows 7 Enterprise 64bit
 
 

Hey, it's me again I have got some weird problem here. Installing Win 7 Enterprise 64bit on new and shiny computer. I have spent 2 days in Audit mode now installing drivers and other stuff. Now I would like to relocate Users and ProgramData folder. I have been doing this before on the old computer and it worked, that's why I am confused now.

Problem is, that sysprep.exe is not there where it should be. C:\Windows\System32\sysprep contains only empty folder "en-US". Same goes for C:\Windows\SysWOW64\sysprep.

I tried searching whole C: and it found it only once at this weird location:
C:\Windows\winsxs\amd64_microsoft-windows-sysprep_31bf3856ad364e35_6.1.7600.16385_none_4b73926c122be805\sysprep.exe

I am not really sure if I am supposed to use this one.

Anyway, only difference from the PDF guide is the dialog of sysprep tool when first booting to it from installation. I have been using another tutorial of yours and there is stated:

Quote:
Now let's quit Sysprep t be able to customize Windows and install drivers and software. Select System Cleanup Action: Enter System Audit Mode and Shutdown Options: Quit as shown below and click OK
Could this cause the problem ? I tried restarting windows, dialog is always appearing again and I had hit Cancel, but to no use.
My System SpecsSystem Spec
25 Feb 2013   #596
Kari

Microsoft Community Contributor Award Recipient

 

No, that is not the issue. I have never heard or seen about an empty sysprep folder. If your install media is valid, and you have done a normal install, it should be there.

I have to do some research, as I said this is the first time ever I have heard anything like this.

I have a suggestion, but I need first really warn you: I believe the tip below works, but as I cannot be sure I simply refuse any kind of responsibility if it fails. You need to understand the risks and that it might cause you losing the Windows functionality.

OK, the tip: Use sysprep from component storage folder (WinSxS) by running your answer file as follows:
Code:
C:\Windows\winsxs\amd64_microsoft-windows-sysprep_31bf3856ad364e35_6.1.7600.16385_none_4b73926c122be805\sysprep.exe /audit /reboot /unattend:DRIVE:\RELOCATE.XML
Interested to hear how it went...

Kari
My System SpecsSystem Spec
25 Feb 2013   #597
FredyC

Windows 7 Enterprise 64bit
 
 

Ok seems solved now, but I am not sure how and why. I again tried to do what is quoted up there in my post and that way the sysprep.exe stayed where it should. Although it had reset some settings like taskbar icons, but that's not big deal, since this is just admin account. I just hope it will be really moved once I finish it here.
My System SpecsSystem Spec
26 Feb 2013   #598
scorpio1

win7 hom 64
 
 

hello it's working i have complete it, it's really simple good work kari you have make e good tutorial .
thx for the help
My System SpecsSystem Spec
26 Feb 2013   #599
Kari

Microsoft Community Contributor Award Recipient

 

That was good news! Happy computing, Scorpio.

Kari
My System SpecsSystem Spec
Comment

 User Profiles - Create and Move During Windows 7 Installation




Tutorial Tools Search this Tutorial
Search this Tutorial:

Advanced Search




Similar help and support threads
Windows 7 Tutorial Category
Help with User Profiles in Windows Server 2008
Hey guys and ladies. So i have scoured the forums looking for answers to my problem and have yet to get a definitive fix. It may just be me though lol. So I am an IT technician for some schools and i have just implemented a new server. It is running Windows Server 2008. My client machines are...
General Discussion
Windows 7 User profiles issue - Shows logging off after entering corru
This issue has become specific as fixing one problem led to the other: 1) I deleted ntuser.* files while working in linux as they had ugly looking file extensions and I thought they are temporary files. 2) I started getting the message "The Group Policy Client service failed the logon....
Installation & Setup
cannot create new user profiles
Win 7 Home Premium. Optiplex 755. I have a working user profile with administartive rights which works fine. I also have a working guest user. However when I try to create a new user, standard or administator, the new user is shown in "mange users" but cannot be logged into. This happens in safe...
General Discussion
Can't move user profiles
Guys ... opening this as separate thread as previous one took a direction of its own. Scenario As per Tutorial moved my profiles off the C:\ http://www.sevenforums.com/tutorials/87555-user-profile-change-default-location.html In order to use Windows Repair/Upgrade Disk I need to move them...
Installation & Setup
How do I move my user profiles back to C:\user
On advice here to keep OS disk space small, followed the tutorial http://www.sevenforums.com/tutorials/87555-user-profile-change-default-location.html and moved my user profile from C:\user\name to E:\user\name The problem is Windows upgrade (need to run for repair) will not accept profiles...
Installation & Setup
New to Win7 move User profiles or use Libraries?
I have just upgraded from Vista where we had two user account profiles on the D partition, as I recall, Vista prompted me to set it up this way initially. I got used to using this method, as my single hdd is divided into two partitions, C for the OS and D for Data. I did a new clean install of...
General Discussion


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 00:13.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App