Re: [man-pages RFC PATCH v4] statx, inode: document the new STATX_INO_VERSION field

From: NeilBrown
Date: Mon Sep 12 2022 - 23:31:43 EST


On Tue, 13 Sep 2022, Dave Chinner wrote:
>
> Indeed, we know there are many systems out there that mount a
> filesystem, preallocate and map the blocks that are allocated to a
> large file, unmount the filesysetm, mmap the ranges of the block
> device and pass them to RDMA hardware, then have sensor arrays rdma
> data directly into the block device. Then when the measurement
> application is done they walk the ondisk metadata to remove the
> unwritten flags on the extents, mount the filesystem again and
> export the file data to a HPC cluster for post-processing.....

And this tool doesn't update the i_version? Sounds like a bug.

>
> So how does the filesystem know whether data the storage contains
> for it's files has been modified while it is unmounted and so needs
> to change the salt?

How does it know that no data is modified while it *is* mounted? Some
assumptions have to be made.

>
> The short answer is that it can't, and so we cannot make assumptions
> that a unmount/mount cycle has not changed the filesystem in any
> way....

If a mount-count is the best that XFS can do, then that is certainly
what it should use.

Thanks,
NeilBrown