This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: XFS reports lchmod failure, but changes file system contents
- From: Al Viro <viro at zeniv dot linux dot org dot uk>
- To: Florian Weimer <fw at deneb dot enyo dot de>
- Cc: "Darrick J. Wong" <darrick dot wong at oracle dot com>, Christoph Hellwig <hch at infradead dot org>, linux-xfs at vger dot kernel dot org, libc-alpha at sourceware dot org, linux-fsdevel at vger dot kernel dot org, Rich Felker <dalias at libc dot org>
- Date: Wed, 12 Feb 2020 19:51:18 +0000
- Subject: Re: XFS reports lchmod failure, but changes file system contents
- References: <874kvwowke.fsf@mid.deneb.enyo.de> <20200212161604.GP6870@magnolia> <20200212181128.GA31394@infradead.org> <20200212183718.GQ6870@magnolia> <87d0ajmxc3.fsf@mid.deneb.enyo.de>
On Wed, Feb 12, 2020 at 08:15:08PM +0100, Florian Weimer wrote:
> | Further, I've found some inconsistent behavior with ext4: chmod on the
> | magic symlink fails with EOPNOTSUPP as in Florian's test, but fchmod
> | on the O_PATH fd succeeds and changes the symlink mode. This is with
> | 5.4. Cany anyone else confirm this? Is it a problem?
>
> It looks broken to me because fchmod (as an inode-changing operation)
> is not supposed to work on O_PATH descriptors.
Why? O_PATH does have an associated inode just fine; where does
that "not supposed to" come from?