I can't find a way to log only the changes in the output of a robocopy execution, i.e.: those considered new file, new directory, newer file, extra file, or extra directory.

The default output as I have it now consists of a list of all directories (touched or untouched) that were considered in the copying. I want to suppress the untouched.

Help doesn't seem to show a way to do this.

  • What are the actual parameters you're using? Did you try with/without the verbose flag? – Seth May 2 '17 at 9:14
  • I use robocopy src dest /mir. As I understand it, /v is for showing skipped files (so, all of them), not what I am looking for. – sasha May 2 '17 at 12:40

If you carefully look at the documentation or robocopy /?, you will find the /NDL switch.

Specifies that directory names are not to be logged.

With this you will have no output on individual names for directories (which can be considered a type of progress marker). But "filenames" will include the path.

So for example you would get the following output:

        *EXTRA Dir        -1    C:\Temp\test\
          *EXTRA File                  0        C:\Temp\test\test.txt
100%        Newer                     72        C:\Temp\test.txt
  • Great, thanks Seth. I must have misread the description for /ndl, thinking it meant something else. However, it would be nice for my purposes to also have a line in the output saying that a new directory in source was created since last mirroring. As is now, only locations to new files or as you mentioned extra items that were purged are printed. I use /LOG+:D:\backuplog.txt /TEE /NDL /NP /NS – sasha May 2 '17 at 13:36
  • You won't be able to get that input with the /NDL switch as far as I can tell. Form what I see neither switch combination would remove "just" the "unchanged" directories that are listed. You might be able to use some regular expression (lines with just white spaces and C: in the example?) to remove those lines using an editor that either supports it or a script. – Seth May 2 '17 at 14:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.