Robocopy: Tips From 10 Years of File Server Replacements
I can vouch for Robocopy. I've been using it for at least a decade, and it's the ONLY way I migrate/copy file shares. I've used it for dozens of file server replacements in all sorts of scenerios. It's never let me down, even with TBs of data over slow WAN links. It has so much flexibility. Here's what you need to know:
- It's built into windows going back to 2008, and in the 2003 Resource Kit.
- Normally command-line only, which is a good thing. There is a GUI, but I've never used it. Most commands take only a few minutes to create and I run from a Batch file so I can rerun it over and over.
- Even when moving small amounts of file server data, I never recommend using Explorer GUI which is slower, and ripe with permissions/ownership issues and prompts. Explorer has no testing, logging, or autoretry.
- Always test to ensure you're getting the results you expect.
- I usually run it from the server I'm copying from. It's faster that way when dealing with 100k+ files vs. running from server I'm going to. Expecially when using multiple passes.
- Never copy someone elses command line and use it. Way too many switches that can cause you to lose data. With much power comes much responsibility.
/?gives you lots of info.
- I tend to run it over many passes. So for a migration of 500GB of file server data, I'll start the first copy days/weeks before the go-live on new server. Each time I run it (depending on switches) it'll only copy updated files... making the copies faster and faster each time. On go-live day, it'll only copy the files changed that day.
- Newer versions even have options for entering delay, to prevent from saturating WAN links.
- In newer versions, mutithread is on by default (8 threads).
- It will retry by default if file is open, and often will retry way to many (2012 R2 retry default is one million) so I always set it to 10 or something reasonable
- Use restartable if using large files over slow links, so if things get interrupted, it can start where left off.
- It's easy to throw the command in a Batch file (with proper logging options) and put in Scheduled Task for running even when you're not logged in (good for multi-day operations).