INTRODUCTION

Robocopy is a Win32 console-mode application designed to simplify the task of maintaining an identical copy of a directory tree in multiple locations, either on the same machine, or in separate network locations. Robocopy effectively provides file replication on demand.

Robocopy is robust. If Robocopy encounters recoverable network errors whilst scanning directories or copying files it will simply wait a while and retry the operation. You can control the time between retries and the number of retries to attempt before giving up.

Robocopy is efficient. By default, if a file exists in both the source and destination, Robocopy will only copy the file if the two files have different timestamps, or different sizes. This saves time if the source and destination are separated by a slow network link. Optionally, you may specify that copies are restartable in the event of a copy failure to save even more time if your network links are unreliable.

Robocopy is flexible. You can choose to copy a single directory, or walk a directory tree. You can specify multiple filenames and wildcards to select which source files are candidates for copying. You can exclude source files from being copied by name, path, wildcard, or file attributes. You can exclude directories from being walked by name or path. You can chose to copy only files with the Archive attribute set, and you can choose whether or not to turn off the Archive bit in the source file after copying. The program classifies files by whether or not they exist in the source directory, the destination directory, or both. In the latter case the program further classifies files by comparing time stamps and file sizes between the source file and the corresponding destination file. You have complete control over which of these file classes will be copied. You can also choose to move files rather than copy them. And you can also choose to purge (delete) destination files and directories that no longer exist in the source, and thereby maintain the destination as an exact replica of the source.

Robocopy is informative. Robocopy produces console output (which can be redirected to a disk file for later perusal) which lists the directories processed, which files are copied (and why), network errors, and incompatibilities between the source and destination directory tree structures. Optionally, you can also ask Robocopy to show estimated time of arrival of copied files, list which files are skipped (and why), and highlight differences in the structure of the source and destination trees that might merit further investigation, or require housekeeping. By default, Robocopy displays copy progress indication (% copied) for each file.

Finally, Robocopy runs fine as a scheduled job. Just configure the Schedule service to log on as a user who has appropriate access to the source and destination directories, and specify remote directories as UNC names on the scheduled Robocopy command line.