samba-bugs at samba.org
2011-Aug-02 18:59 UTC
[Bug 8342] New: rsync can't handle populate dirs without u+rx permissions
https://bugzilla.samba.org/show_bug.cgi?id=8342
Summary: rsync can't handle populate dirs without u+rx
permissions
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
populated.
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.
samba-bugs at samba.org
2011-Aug-02 19:02 UTC
[Bug 8342] rsync can't handle populate dirs without u+rx permissions
https://bugzilla.samba.org/show_bug.cgi?id=8342 --- Comment #1 from Christopher Key <cjk32 at cam.ac.uk> 2011-08-02 19:02:32 UTC --- Created attachment 6748 --> https://bugzilla.samba.org/attachment.cgi?id=6748 patch described in bug 8342 -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug.
samba-bugs at samba.org
2011-Sep-10 21:17 UTC
[Bug 8342] rsync can't handle populate dirs without u+rx permissions
https://bugzilla.samba.org/show_bug.cgi?id=8342 --- Comment #2 from Wayne Davison <wayned at samba.org> 2011-09-10 21:17:47 UTC --- I have included the patch to have rsync temporarily tweak dirs with u+r and u+x for a non-root receiver, however if a parent dir lacks u+x, any fudged permissions inside subdirs of that directory won't get fixed, and indeed, an incremental recursion copy can tweak the parent dir's permissions back to u-x too soon for the copy to even complete (the latter of which you can work around via --no-inc-recursive because the directory-permission cleanup all happens at the end with --no-i-r). I'll leave this open pending contemplations of a fuller fix, but it may just be that we don't fully support non u+x hierarchies for non-root transfers. -- Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug.
Maybe Matching Threads
- Group "None" after synching to a windows machine?
- winbindd wbinfo -u - can't populate
- [Bug 10756] New: rsync can't create files or dirs in subdirs (sometimes?)
- FLAC 1.2.0 won't build without ogg
- DO NOT REPLY [Bug 3543] New: [ACL] rsync calls default_perms_for_dir on omitted implied dirs before ensuring they exist