Link to home
Start Free TrialLog in
Avatar of MCloud1983
MCloud1983

asked on

Robocopy - Copy the contents of a Windows 2003 File Server with all of its permissions to a 2012 Windows Server

Can you tell me how to copy the contents of a Windows 2003 File Server with all of its permissions to a 2012 Windows Server?
Avatar of NVIT
NVIT
Flag of United States of America image

Assuming you are copying data files...

Assuming you are running robocopy from 2012 server...
d$ = source of data folder

IMPORTANT: To verify, you should do this on a test folder branch first

robocopy "\\server2003\d$\data" "d:\data" /npp /r:1 /w:1 /copyall /e /mir /dcopy:t /log:c:\robocopy_log.txt

Open in new window

You can only do this if the servers are on the same domain.  Further, this can be easily done by capturing the existing data drive into a VHD using Disk2VHD and attaching it to the new 2012 server VM.  (You ARE virtualizing right?  Not throwing away an extra server license and making disaster recover more difficult by installing physically...)
Avatar of MCloud1983
MCloud1983

ASKER

Lee, I hadn't thought of the option that you're suggesting.  The 2003 system is virtual and the data drive, E:\, is 1.61 TB.  So, how would I go attaching this drive to a 2012 VM?  Do the different operating systems pose a problem?
No problem at all - especially going older to newer.  (Even newer to older USUALLY works).
Don't know what virtualization platform you're using, but if Hyper-V, add the drive in the VM config (you MIGHT have to add a SCSI controller and then a hard disk; when adding the hard disk, specify your original disk (if you use VMWare, I'm pretty sure the process will be similar, but I don't use VMware and can't be 100% certain of the steps).
NVIT, I don't see a /npp switch only /np.  Am I missing something?  Is there a distinction?
/np is correct.
Sorry about that.
NVIT, I've found out that Robocopy doesn't copy the root folders just subfolders and files.  I created a .bat file to create the root folders and that works okay, but the downside is that none of the root folders' sharing information is copied.  Is there a remedy for this shortcoming?  If not, I'll have to go to the root folders and share them if that feature is required.  And, thanks so much for your help.
It should copy root, too. What does your command look like?
NVIT, it's what you recommended, but it doesn't create the root folder unless I list it.  I created a batch file to create the root folders because there are seventy (70) root folders on the E drive and I didn't want to do it manually on the command line.  Because of the batch file it finishes one folder and moves on to the next one until completed.  The issue I'm having is with root folders that have been shared.  The sharing feature is not being created although the other items, security in particular, are.  The following is one line of the batch file: robocopy \\server2003\e$\Storagedata e:\Storagedata /np /r:1 /w:1 /copyall /e /mir /dcopy:t /log:c:\robocopy_log.txt.

One of my co-workers mentioned Double - Take Move as an alternative.  He swears by it.
ASKER CERTIFIED SOLUTION
Avatar of NVIT
NVIT
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
NVIT, I'll run it tomorrow and let you know the outcome.  By the way, get ready for the share question.  Thanks.
Confused as to why you're taking the long way... but ok...
NVIT, yes, for the ones that did work at the target e:\Storagedata I confirmed the Security permissions of the files and folders.
NVIT, what long way are you referring to?  Have I missed something?
Disconnecting the virtual hard disk from the old server and attaching to the new.  Transfer takes seconds, not hours.
You did say:
The 2003 system is virtual and the data drive, E:\, is 1.61 TB.  So, how would I go attaching this drive to a 2012 VM?
Lee, I'm sorry.  I've been texting NVIT a lot, so I thought you were he.  The Technology Office believes that the detachment and reattachment of the virtual hard drive to a different virtual machine may be too risky.  Although they agree that it should work technically they're worried that it could fail and the hard drive may become corrupted or defective in some way.  It's a lot of data and no one wants to take the risk, so I believe my options are Robocopy or Double - Take Move.  I hope to test your theory in the near future, but I have to take an action to migrate the File Server this weekend.
That's beyond silly.

You shut down the existing VM, remove the drive, attach to the new drive VM and power on if you want to play it safe - hot add is also supported in Hyper-V and 2012.  I've NEVER had a corruption doing this.  

Besides, you should have BACKUPS!  What would happen if the existing array failed?  Indeed, I've used robocopy in the past and had half the data inexplicably corrupted by that!  Happened at a client 15 months ago going from 2008 R2 to 2012 R2.  Moving the disk is SAFER in my experience and opinion, especially when you think about everything that CAN go wrong!
(Incidentally, we robocopied from a VMWare VM to a Hyper-V host using the 2012 R2 Robocopy, in total, about 1.2TB of data).
Heck, you really want to play it safe, copy the existing Virtual hard drive off to another system, test it, and that's you're backup.  Copying one VERY LARGE file will go a LOT faster than copying thousands or millions or small files!
If I had my druthers I'd detach and reattach the virtual hard drive to the new virtual machine, but since it hasn't been tested no one wants to take the risk especially with the amount of data involved.  Again, I plan on testing it after this  weekend's migration is completed.  It'll be a perfect time to do it.  Since 2003 and 2012 servers are involved in the migration I didn't think of it and neither did the Technology Office.  Thanks again for the suggestion.
NVIT, your command worked (robocopy \\server2003\e$ e:\ /np /r:1 /w:1 /copyall /e /mir /dcopy:t /log:c:\robocopy_log.txt.).  The root folders were copied along with the Security permissions, but the folders that were initially listed as shared were not shown as shared after using the Robocopy.  So, now I'll post the Robocopy sharing question.  You had the best solution for this task.  Thanks.