Hacker News new | ask | show | jobs
by randkyp 814 days ago
I found this recent thread interesting, specifically about really considering whether you're going to read the data you just wrote in the near future or not (in which case, use direct IO) and a set of (abandoned?) patches for write-behind caching for sequential writes in Linux (https://lore.kernel.org/lkml/156896493723.4334.1334048120714...).

https://lore.kernel.org/linux-mm/45odvhgymm7fxsgwpewoiiggaok...

1 comments

Direct IO is very inflexible. A better way is this recommended by Linus in an old post:

https://lkml.iu.edu/hypermail/linux/kernel/1005.2/01845.html

I implemented something along the same lines but a bit less spicy here:

https://gitlab.com/nbdkit/nbdkit/-/commit/aa5a2183a6d16afd91...