fix setting selinux context on file with r/o permissions
If you do this on a ganesha NFS mount with SELinux enabled, it will fail (as shown):
openat(AT_FDCWD, "/mnt/cephfsgw1/jlayton/opentest.new", O_RDWR|O_CREAT|O_EXCL, 0444) = -1 EACCES (Permission denied)
What happens is that the create works just fine, but then ganesha does a follow-on setxattr to set the SELinux context. That fails because the mode doesn't allow writes and I'm not a privileged user.
This wouldn't be such an issue, but git happens to create files like that so that makes git clone break.
There are a couple of potential solutions but they are all quite ugly. I'll have to do some exploration as to the least ugly fix.
#2 Updated by Jeff Layton 3 days ago
Fixed in ganesha's next branch: