Hi, the reason is the following: ecryptfs_privileged_open: https://github.com/torvalds/linux/blob/v4.19-rc4/fs/ecryptfs/kthread.c#L126 https://github.com/torvalds/linux/blob/v4.19-rc4/fs/ecryptfs/kthread.c#L147 IS_RDONLY is defined through sb_rdonly: https://github.com/torvalds/linux/blob/v4.19-rc4/include/linux/fs.h#L1916 and the reason is: https://github.com/torvalds/linux/blob/v4.19-rc4/include/linux/fs.h#L1906 *Exception: SB_RDONLY is always applied to the entire file system.* Therefore i think the code should not always try to get a read/write file and fail if this is not possible. Instead the code should open the file read-only if an error has occured due to permissions. If this is still not possible, the code should fail. Best Regards Hajo Am 15.09.2018 um 01:10 schrieb Alex Braunegg: > This issue sounds very similar to this one I brought up in 2014: > > https://www.spinics.net/lists/ecryptfs/msg00567.html > > I never got to the bottom of why it was occurring - but did look at the > kernel code at the time to see what was going on but I cannot recall what I > found out. > > Best regards, > > Alex > > -----Original Message----- > From: ecryptfs-owner@xxxxxxxxxxxxxxx [mailto:ecryptfs-owner@xxxxxxxxxxxxxxx] > On Behalf Of Christian Kujau > Sent: Friday, 14 September 2018 4:30 PM > To: Hans-Joachim Kliemeck > Cc: ecryptfs@xxxxxxxxxxxxxxx > Subject: Re: combination of cifs and ecryptfs not working - readonly > problems > > On Sun, 2 Sep 2018, Hans-Joachim Kliemeck wrote: >> remote cifs server: >> seems to be a proftpd with mod_sftp (with CIFS Unix Extensions), but i > This sounds....rather exotic :-) > > I tried to emulate your setup with a standard Samba v4.8.2 server but > could not reproduce the issue: > > # mount | tail -2 > //sid0/test on /opt/backup/remote-encrypted type cifs > (rw,relatime,vers=1.0,sec=none,cache=strict,domain=SID0,uid=0,noforceuid,gid > =0,noforcegid,addr=192.168.56.130,unix,posixpaths,serverino,mapposix,acl,rsi > ze=1048576,wsize=65536,echo_interval=60,actimeo=1) > /opt/backup/remote-encrypted on /opt/backup/remote type ecryptfs > (rw,relatime,ecryptfs_sig=5e0685315ad3478b,ecryptfs_cipher=aes,ecryptfs_key_ > bytes=32,ecryptfs_unlink_sigs) > > ...and rsync did finish w/o errors. So maybe we'd need to look at the > server's mod_sftp log files to see what's going on here..? > > Note: Hetzner appears to support many other backup mechanisms[0], > including BorgBackup, that may be something to look into. > > Christian. > > [0] https://wiki.hetzner.de/index.php/Backup