[Samba] User Profile Migration Solved

Erwin Zierler erwin.zierler at stubainet.at
Fri Jan 17 09:27:00 GMT 2003


Migration of User Profiles

Goal:
Old machine with NT 4.0SP6 running as a primary domain controller (PDC)
is to be replaced by a new Linux server running samba 2.2.7a.
The samba version I used was a precompiled rpm package from SuSE.

Environment:
14 Windows 2000 Professional (SP1-SP3) Workstations with 1-2 User accounts
  3 Windows NT 4.0 WS (SP6) Workstations with 1-2 User accounts
All these are German versions in case it matters for anyone, but I will
try use the English equivalents for folder names and the like where ever
possible.

After invesigating the workstations I found out that all user profiles
were local (not roaming) so no profiles on the PDC.
Further investigation revealed that 4 users had 350MB - 2.4GB data under
C:\Documents and Settings\USER\ which to some extent explains why they
didn't use roaming profiles. Like on many other computers I have seen
in the past people just get into the habit of creating files and folders
on their Desktop for convenience. No average user however is aware that
their Desktop is actually physically located in
'C:\Documents and Settings\USER\Desktop' (or in case of WinNT
'C:\WINNT\Profiles\USER\Desktop') and therefore, if roaming profiles are
used, will slow down especcially every logoff process, since all these data
stored on the desktop have to be copied over to the server. There are ways
to prevent this but introducing proper user policies is the better choice.
Educate your users and you (and even they) will be happier once they stick
to these rules.

Now for the migration process.

1. Log on to your old PDC as administrator and create a public share to store
the local profiles of all workstations, let's call it temp_profiles.
As an alternative you can store them on the local workstation as well
but for savety reasons I wanted to make sure I had a copy on the server.

2. Log on as local Administrator to each of your W2K/WinNT workstations,
right click on 'My Computer', then select the tab labelled 'User Profiles'.
Select a user profile you want to migrate and click on it. In my case
user profiles are labelled PCxx\username (xx were numbers from 01 to 26).
Click on 'Copy To' and in the following box labelled 'Copy Profile to'
enter the path to the temporary folder (i.e. \\old_server\temp_profiles).
Make sure you also click on the button labelled 'Change' in the
'Permitted to use' box and add the group 'everyone'. If you skip this step
chances are high that certain programs wont work later. Click 'OK' to save
the user profile on the server (or if you perfer you can save them locally
on each workstation - should not make a difference but is untested).

3. Next you leave the DOMAIN and join a temporary WORKGROUP (in my case
I choose the same name for both). On W2K you can find this by right-clicking
on 'My Computer' -> 'Properties' and in the next box click the tab labelled
'Network Identification'. Click the button 'Properties' and you'll see
where you can change from domain to workgroup logon. Then reboot.
This you have to do for each client of course. Under WinNT the process is
slightly different and is left as an exercise for the user.

4. Disable your old NT PDC and start the samba server with PDC functionality
enabled. By this time you should have created all your user accounts including
a special root account (i.e. you must add root to smbpasswd as explained in the
samba documentation). The root account is needed for joining the domain.
Also make sure you have set up machine accounts, either manually or with the
'add user script' option in smb.conf.

5. Log on as local administrator to all your workstations again and now 
join the
new samba domain. Under W2K a box will appear asking you for a username and
password. Use 'root' as user and the password you set in smbpasswd for root.
When everthing goes right you will see something like 'Welcome to the 
domain ...'
Reboot again.

6. You can now log on to the workstations as regular user. Log off again right
away, and you will find a freshly created profile for each user on the samba
server and each workstation under 'C:\Documents and Settings\USER.DOM\'.

7. Log on to each workstation as administrator again, make sure you have
access to the temporary location with the previously saved user profiles
and now copy all the contents over the fresh profiles which were just created.
So you are actually overwriting the local AND the serverbased profiles.

8. Now you can log on as a regular user on each workstation and will find
your beloved 'old' settings including all program settings, desktop icons,
wallpapers and other more or less useful details. In my case this included
settings for MS Office, several Adobe and Autodesk products. Even MS Outlook
worked again since the *.PST files were located on the server already
in the old environment. Users have not reported any errors so far except
they now have to provide a password to log on to the domain which was
not necessary before ;-)

My thank goes to John H Terpstra for providing alot of essential information
and even offering to call me in case I got stuck :-)

Hopefully this little document can help some others who are trying to
achive the same or a similar goal. I am aware that this is maybe not the
only solution for this particular problem but it has worked well for me
so it might work for others.

Regards,
  Erwin Zierler





More information about the samba mailing list