[Bug 8342] New: rsync can't handle populate dirs without u+rx permissions

samba-bugs at samba.org samba-bugs at samba.org
Tue Aug 2 12:59:33 MDT 2011


           Summary: rsync can't handle populate dirs without u+rx
           Product: rsync
           Version: 3.0.9
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P5
         Component: core
        AssignedTo: wayned at samba.org
        ReportedBy: cjk32 at cam.ac.uk
         QAContact: rsync-qa at samba.org

When running rsync with root at the source, it is quite possible to end up
wanting to transfer directories with 'strange' permissions.  At present, it the
destination doesn't have root access too, these directories cannot be

For example:

# mkdir source
# mkdir source/dir
# touch source/dir/file
# chmod 400 source/dir
# sudo rsync -rltp source user at host:destination
rsync: recv_generator: failed to stat ".../destination/source/dir/file":
Permission denied (13)

In order to create files in a directory without root, it needs to have u=rwx
permissions.  There is currently a workaround to temporarily add u+w write
permissions to a directory whilst creating files and to correct the permissions
afterwards, specifically to deal with read-only directories (u=rx).  The
attached patch extends this to temporarily add u+rwx permissions instead,
allowing all directories to be transferred.

Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

More information about the rsync mailing list