I have two hard drives:
G: is an external USB drive connected to a Windows 10 PC H: is a network drive (another USB drive connected to the USB port of the home network router's USB port)
I have copied all files and sub-folders from G:/my_data_folder onto H:/my_data_folder. Right now, H:/my_data_folder is an exact copy of G:/my_data_folder.
Now I want to create a Robocopy command that I can run periodically on the Win10 PC, that will copy from G: to H:
- any file/folder in G:/my_data_folder that doesn't already exist in H:/my_data_folder
- any file in G:/my_data_folder that does already exist in H:/my_data_folder but is a more recent version (ie, has been saved more recently). This newly copied file will over-write the older file on H:.
My understanding of Robocopy is that NOT copying existing files of the same date/time is the default behavior, so I don't need to explicitly exclude them.
I do NOT want H:/my_data_folder to mirror G:/my_data_folder. That is, never erase anything from H:/my_data_folder, even if it is now absent from G:/my_data_folder.
I don't need a log file, but I want to see what it did on screen.
Here's my attempt to compose the appropriate robocopy command:
robocopy g:/my_data_folder h:/my_data_folder /e /np /fft /mt:8 /z /r:5 /w:5
- /e = copy even empty directories
- /np = no file copy progress - don't need it
- /fft = in case of any date/time errors due to network drive
- /mt:8 = use 8 concurrent threads to speed things up
- /z = restartable mode so it can recover from an interrupted transfer
- /r:5 = try maximum 5 restarts
- /w:5 = wait 5 seconds between restarts
Will this do what I want? Have I missed any critical switches for such a task?