3 ms·
> I would expect a copy-on-write filesystem to be able to do this automatically for free. this is an artifact of how handles work (in relation to concurrency),
by paulmd 5y ago
> I would expect a copy-on-write filesystem to be able to do this automatically for free.
this is an artifact of how handles work (in relation to concurrency), not the filesystem.
copy-on-write still guarantees a consistent view of the data, so if you write on one handle you're going to clobber the data on the other, because that's what's in the file.
what you really want is an operator which says "I want this handle to point to the original snapshot of this data even if it's changed in the meantime", which a CoW filesystem could do, but you'd need some additional semantics here (different access-mode flag?) which isn't trivially granted just by using a CoW filesystem underneath.