One of the most painful parts of any migration to a new IT system is migrating your files from the old server to a new server. In the guide below I will show you how to copy your files with permissions to Server 2012 from your existing server 2003 or server 2008r2 install. I will then show you how to migrate your shares from Server 2003 or Server 2008 to Server 2012. We will keep all share permissions when we migrate the shares and also the shares will not need setting up again once we are complete.
Migrating Files With Permissions To Server 2012
In this example we have our old server drive “E” and we are migrating/copying files with there permissions, to drive “F” on our new server. On your old server first map drive “F” to your new file server. Then drop to a command prompt and CD to drive “E”. We then run the command below, this command copies all files and folders with permissions from source to destination.
xcopy e:*.* f:*.* /D /E /C /F /H /K /O /Y
Of course you may not want to copy the whole content of your old drive to your new server. So in the example below we copy individual folders with all permissions from the old server to the new server.
xcopy e:oldfolder f:newfolder /D /E /C /F /H /K /O /Y
Once you have copied all your files and folders to the new server we are ready to migrate our shares and share settings.
Migrating Shares To Server 2012
This method as mentioned will copy all the shares and share permissions to your new server, it involves backing up a registry key and importing it to our new server. If you can and want to make this even more simple try and keep the drive letter the same on your new server the shares where on your old server, if you cannot, don’t worry we can change it later. On your old server migrate to the following key.
Then right click the Shares key and select “Export”, give it any name you like and save it to an area accessible from your new server.
Now go to your new server, right click the registry file you have exported and select “Merge”. All your shares are now setup on your new server. If your new server uses the same drive letter then there is nothing more to do bar restart the “Server” server. Start>Run>Services.msc then restart the “Server” service. If you drive has a different drive letter to the old server then we need to do the following.
On the new server, again in regedit, browse to the following key.
Now on the right hand side you can see your shares. To change the drive letter of a share simply double click the share in question and then locate the section labeled “path” and change the drive letter to the drive of your new file server as highlighted in the image below.
You will need to do this for each share that you want to change the drive location for. Once complete we need to restart the server services again, start>Run>Services.msc then restart the “Server” service or simply reboot the new server. This process is now complete