Files
seaweedfs/weed
Chris Lu c275e186c8 mount: auto-enable Linux FUSE passthrough for read-only files
On a read-only open, when the kernel supports FUSE_PASSTHROUGH (Linux >= 6.9, privileged mount), materialize the file into a local backing file and register it via RegisterBackingFd so the kernel serves reads and mmap directly from the backing file, bypassing the mount process.

No opt-in flag: support is probed by the first RegisterBackingFd call and latched off on failure, so unsupported mounts transparently use the normal read path. Gated to read-only opens of files up to -fusePassthroughMaxMB (default 256; 0 disables). The backing is shared per inode and torn down when the last open is released; MaxStackDepth is set so the kernel accepts registration.

Tradeoff: a passthrough handle reads a point-in-time snapshot, so concurrent writes are not reflected while the file stays open - best for immutable / read-mostly data. The data path is unchanged when disabled or unsupported, and the feature is a no-op on non-Linux platforms.
2026-06-20 16:05:54 -07:00
..
2026-04-10 17:31:14 -07:00
2026-04-14 20:48:24 -07:00
2026-06-19 09:09:01 -07:00
2026-04-23 10:05:51 -07:00