Reflink usage in VFS cache?

I think it's a pretty good idea to utilize links for the VFS cache write queue.
It should be clarified that this doesn't really depend on reflinks AFAICT (only supported by CoW file systems), but could just use hard links.
Even symlinks, which would be more portable and could be used across mount points, could be used if ensuring that metadata/mtime checks happen on the link target.

The higher level fully portable solution would be to implement and use VFS cache limit checks for writes, i.e. VFS cache exceeds maximum size when caching writes.

1 Like