locked
Access denied (error 0x80070005) when trying to overwrite files on external USB drive RRS feed

  • Question

  • I have recently upgraded to a PC running 64-bit Windows 7 and I am now using SyncToy 2.1(x64).

    Since I have been using this version I have noticed that when Synchronization of a Folder Pair requires some files to be overwritten all the overwrites fail. In each case the error reported by SyncToy is "Error: Cannot write to the destination file. Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED)) Copying ..."

    There is no problem writing new files to the USB drive.

    I have looked at the Properties of some of the files that cannot be overwritten ... the "Read-only" box is unticked.

    It may be relevant that, when I look at the Security tab of the Properties for one of the files that can't be overwritten, my user name is not shown ... the only Group or user names listed are SYSTEM, Account Unknown (S-1-5-.......), Administrators and Users (and Users only have "Read & execute" and "Read" permissions).

    By contrast, when I compare the Security tab for a recently created file I see my User name listed instead of Account Unknown and my user name has "Full control", "Modify" and "Write" permissions.

    I have not encountered similar problems when using SyncToy on files moved from one computer (with one version of Windows) to another (with the same or a different version of Windows). Has this problem arisen because I am now using a different user name on this computer from the one I have used on previous computers?

    I have seen suggestions elsewhere that I should run SyncToy "as administrator". However, I can't see how to do that: when I right-click on the program shortcut there is no "Run as administrator" option in the menu, and when I open the Properties page the "Run as administrator" option is greyed out.

    I am the only user (and therefore, presumably, the administrator) of this computer.

    Any suggestions, please, as to how I can get SyncToy to overwrite files when required?

    Wednesday, May 26, 2010 9:18 PM

All replies

  • I've done a bit of googling and it seems that the problem may have arisen because is Windows 7 is fussier about file access permissions than earlier versions of Windows, and that the answer to my problem might lie in changing the security settings for the destination folder (the folder on the external drive that contains the files that may need to be over-written).

    To test this theory I proceeded as follows. In windows Explorer I right-clicked on one of the sub-folders that contained files needing to be over-written. From the menu I selected Properties. In the Security tab I clicked Edit then selected Users and gave Full Control permissions to the Users group.

    After doing this, I re-ran SyncToy and the files in this particular folder were over-written satisfactorily.

    I'm nervous about fiddling with Security settings which I do not understand. Presumably the security restriction which is impeding SyncToy has been introduced for a good reason and it would be wrong for me to blunder in and relax the permissions willy-nilly. Before going further and changing the security settings for the entire destination folder I would appreciate some assurance that it is OK for me to change Security settings in this way.

    Friday, May 28, 2010 4:27 PM
  • Can anyone advise me, please?

    - Am I right to suspect that the SyncToy errors were caused by file access restrictions?

    - What would be the implications of opening up permissions to give Full Control to Users over all my backup folders?

    • Proposed as answer by Das187 Sunday, June 6, 2010 7:30 PM
    Tuesday, June 1, 2010 6:24 PM
  • Humm I think I just epic failed a reply.  Nice.

     

    Anyway..the problem you have is with UAC. 

    In order to run SyncToy as an admin, you can do one of two things. 

    1. Hold down the shift key and right click the SyncToy shortcut and click Run as administrator

    2. Create a new shortcut to SyncToy.exe > Right click on the new shortcut > Properties > Advanced > check Run as administrator.

    • Proposed as answer by Das187 Sunday, June 6, 2010 7:46 PM
    Sunday, June 6, 2010 7:37 PM
  • This worked for me as well...

    Friday, November 10, 2017 11:08 PM