backuprobocopylocked-files

how to copy files in use with robocopy?


I am having a batch file performing some backup operations. The backup operations look like this:

robocopy %source% %root%\%targetname% /MIR /R:0 /W:0 /NFL /NDL /NJS

Unfortunatly some files in use cannot be copied due to windows "protection". Is there the possiblity to copy files in use?

I am using windows 10. The backup included in windows 10 is not flexible enough, i cannot just copy some folders and so on.


Solution

  • According to Wikipedia:

    Robocopy does not copy open files. Any process may open files for exclusive read access by withholding the FILE_SHARE_READ flag during opening. Even Robocopy's Backup mode will not touch those files.