Dimitrios Apostolou
2019-Dec-09 00:56 UTC
How Can I save the original permissions while setting g+rX for all files
Hello list! Combining -M--fake-super with --chmod ends up changing the permissions stored in the fake-super xattrs. I.e. the permissions stored in the xattr, are affected by --chmod. The desirable behaviour for me would be for --chmod to modify the real permissions of the destination files. The use case is writing a backup as a non-root user, having it readable by the group (g+rX), while also saving the original permissions in the xattr. Is it a bug? Any suggestions on how I can achieve what I want? Thanks in advance, Dimitris
Kevin Korb
2019-Dec-09 01:11 UTC
How Can I save the original permissions while setting g+rX for all files
When I try it the chmod works on both the real permissions and the permissions in the xatttr. Maybe the behavior has changed since whatever version you have (3.1.3 here) but this probably wouldn't help you either. On 12/8/19 7:56 PM, Dimitrios Apostolou via rsync wrote:> Hello list! > > Combining -M--fake-super with --chmod ends up changing the permissions > stored in the fake-super xattrs. I.e. the permissions stored in the > xattr, are > affected by --chmod. > > The desirable behaviour for me would be for --chmod to modify the real > permissions of the destination files. The use case is writing a backup as a > non-root user, having it readable by the group (g+rX), while also saving > the > original permissions in the xattr. > > Is it a bug? Any suggestions on how I can achieve what I want? > > > Thanks in advance, > Dimitris > >-- ~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._., Kevin Korb Phone: (407) 252-6853 Systems Administrator Internet: FutureQuest, Inc. Kevin at FutureQuest.net (work) Orlando, Florida kmk at sanitarium.net (personal) Web page: https://sanitarium.net/ PGP public key available on web site. ~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._.,-*~'`^`'~*-,._., -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 195 bytes Desc: OpenPGP digital signature URL: <http://lists.samba.org/pipermail/rsync/attachments/20191208/cfc9878a/signature.sig>
Dimitrios Apostolou
2019-Dec-09 01:18 UTC
How Can I save the original permissions while setting g+rX for all files
Yes indeed, it is setting both the permissions. So it sets the desirable access rights to the file, but does not save the original mode in the xattr. So it's not really working out for me. On Monday, December 9, 2019 2:11:23 AM CET, Kevin Korb via rsync wrote:> When I try it the chmod works on both the real permissions and the > permissions in the xatttr. Maybe the behavior has changed since > whatever version you have (3.1.3 here) but this probably wouldn't help > you either. > > > On 12/8/19 7:56 PM, Dimitrios Apostolou via rsync wrote: >> Hello list! >> >> Combining -M--fake-super with --chmod ends up changing the permissions >> stored in the fake-super xattrs. I.e. the permissions stored in the >> xattr, are >> affected by --chmod. ... >
Seemingly Similar Threads
- How Can I save the original permissions while setting g+rX for all files
- Would you expect --perms -M--fake-super to set the file mode to the original one?
- Would you expect --perms -M--fake-super to set the file mode to the original one?
- Would you expect --perms -M--fake-super to set the file mode to the original one?
- DO NOT REPLY [Bug 7112] New: --fake-super should use default permissions for real files