How to use Robocopy to eXclude Directories?

/XD dirs [dirs]... :: eXclude Directories matching given names/paths.

RoboCopy D:\ Z:\ /MIR /R:1 /W:1 /XD D:\System Volume Information\, does anyone have any suggestions on how to exclude one directory for Robocopy function?

I don't understand that I cannot see any directory under D: drive called "System Volume Information", when robocopy executes its command, this directory shows on the screen, if there is only one hidden system directory, it will be fine, but what about there are 3000 thousands this kind of directories, then it will not be wise to exclude them one by one. Referring to robocopy.txt, there is no option to exclude any hidden system directory.

Do you have any suggestions on any better approachs to handle this case?

 

Question Info


Last updated July 5, 2019 Views 2,666 Applies to:
Answer
Answer

Hi,

 

You can refer to these links for more information on the different commands and how to use RoboCopy:

 

How to Use Robocopy to copy security information without copying any file data

http://support.microsoft.com/kb/323275

 

Return codes that are used by the Robocopy utility in Windows Server 2008

http://support.microsoft.com/kb/954404

 

You can also refer to:

http://en.wikipedia.org/wiki/Robocopy

 

Hope this helps

John Rubdy
Forum Moderator | Microsoft Community

Did this solve your problem?

Sorry this didn't help.

Great! Thanks for marking this as the answer.

How satisfied are you with this reply?

Thanks for your feedback, it helps us improve the site.

How satisfied are you with this response?

Thanks for your feedback.