Copy Contents of One Hard Drive to Another in Windows
I, infrequently, need to copy the entire contents of one disk to another in Windows. Usually when upgrading a hard drive. This is the best command I’ve found so far to do that:
robocopy d:\ g:\ /eta /e /dcopy:T /r:1 /w:1
d:
- source driveg:
- destination drive/eta
- show the ETA/e
- copy sub-directories, including empty directories/dcopy:T
- copy directory time stamps/r:1
- set number of retries on failed copies to 1, the default is 1,000,000(!), some files might error, but I don’t care about retries as it’s not over a network/w:1
- set wait time (in seconds) between retries, the default is 30
Hopefully others find this useful. At the very least future me will, if he remembers this post exists.
See the robocopy help for more info and options.