[LU-12480] add STATX_PROJID to upstream kernel Created: 27/Jun/19  Updated: 19/Sep/23

Status: Open
Project: Lustre
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Minor
Reporter: Andreas Dilger Assignee: WC Triage
Resolution: Unresolved Votes: 0
Labels: lad23dd, lug23dd, medium, quota

Issue Links:
Related
is related to LU-12511 Prepare lustre for adoption into the ... Open
is related to LU-10934 integrate statx() API with Lustre Resolved
is related to LU-12056 tar doesn't support project id Resolved
is related to LU-15519 fallocate does not increase projid qu... Resolved
is related to LU-16085 Ubuntu 22.04 sanityn test_106c: suppo... Resolved
is related to LU-11872 Request for option not to follow syml... Resolved
is related to LU-15837 "lfs find -printf" improvements Open
is related to LU-15372 add projid to changelog Open
is related to LU-15723 Add fget_projid() to llapi Open
is related to LU-9555 "df /path/to/project" should return p... Resolved
Epic: quota
Rank (Obsolete): 9223372036854775807

 Description   

Support for statx() was landed to Lustre 2.14 in LU-10934, and I realize that the upstream kernel does not support requesting the project ID as part of that interface.

It would be very useful to add a new STATX_PROJID = 0x2000 flag to the upstream kernel, and integrate this into the statx() handling for ext4, xfs, and f2fs if that is easy. It seems possible to use the sb->dq_op->get_projid() interface to fetch this at the VFS level, if available. The STATX_ATTR_PROJINHERIT = 0x20000000 flag should be added to stx_attributes_mask.

While it may take some time to get this into a kernel that we are using, better to start it now, and once it is landed upstream we can at least request to get it added to RHEL8 or similar.

You should add David Howells <dhowells@redhat.com> to the CC list for the patch review.



 Comments   
Comment by Andreas Dilger [ 14/Apr/22 ]

Shilong had submitted patches for this, but it looks like they were not accepted for minor reasons:
https://lore.kernel.org/linux-fsdevel/1551449141-7884-6-git-send-email-wshilong1991@gmail.com/

and a test case for xfstests:
https://lore.kernel.org/linux-fsdevel/1551449184-7942-2-git-send-email-wshilong1991@gmail.com/

The fchownat() interface changes were less warmly welcomed, so it makes sense to resubmit the statx() enhancement by itself with the review comments addressed.

Generated at Sat Feb 10 02:52:57 UTC 2024 using Jira 9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c.