New
#1
Robocopy Backup - ERROR 5 (0x00000005)
Hi,
I'm wondering if anyone might be able to shed some light on why I am getting the following such errors when running a robocopy batch file (as administrator) which cause the backup script to stall (- albeit temporarily):
I am using the following backup command:2013/07/30 21:10:43 ERROR 5 (0x00000005) Copying File C:\Users\Tim\My Documents\Harey 8-128.jpg
Access is denied.
Waiting 30 seconds... Retrying...
2013/07/30 21:12:20 ERROR 5 (0x00000005) Copying File C:\Users\Tim\My Documents\TimsData\Year1.pdf
Access is denied.
Waiting 30 seconds... Retrying...
2013/07/30 21:15:27 ERROR 5 (0x00000005) Copying File C:\Users\Tim\My Documents\TimsData\Tim\Heddon's Mouth - Printable Walk - South West Coast Path.htm
Access is denied.
Waiting 30 seconds... Retrying...
I realise that if I limit the retries and wait time from the defaults the stall time will be shortened and the file(s) skipped. However, that does not resolve the issue why robocopy is having a problem copying the file(s).Code:robocopy "%srcPath%\My Documents" "%dstPath%\My Documents" /b /v /ts /fp /bytes /tee /e /dcopy:t /copy:dt /a-:sh /xf desktop.* /np /log+:%logPath%\mwk1log.txt
I have found that if the erroring files are moved from the source location to the desktop, the following errors arethen recorded in the log:
... which is understandable as it has been moved. Then the backup script continues. But when I check the destination directory I find the file has been copied anyway!2013/07/30 21:11:13 ERROR 2 (0x00000002) Copying File C:\Users\Tim\My Documents\Harey 8-128.jpg
The system cannot find the file specified.
2013/07/30 21:13:53 ERROR 2 (0x00000002) Copying File C:\Users\Tim\My Documents\TimsData\Year1.pdf
The system cannot find the file specified.
2013/07/30 21:15:57 ERROR 2 (0x00000002) Copying File C:\Users\Tim\My Documents\TimsData\Tim\Heddon's Mouth - Printable Walk - South West Coast Path.htm
The system cannot find the file specified.
Additional Notes:
The target device is an attached external USB drive.
I have already checked that the permissions on the files/folders concerned are correct.
The files affected appear to consistently be .jpg, .pdf or .htm files.
The files do not appear to be corrupt as they can be opened and worked on as required.
The batch file works fine apart from the intermittent errors copying files.
Any advice would be greatly appreciated.