This Article IsCreated at 2024-02-10Last Modified at 2024-02-10Referenced as ia.www.f17

Using Filesystem as Key-Value Database

The idea comes from, where they mentioned page 4 of Hans Reiser’s Letter to me about Reiser’s dream of “unifying filesystem and database”.

In the letter, Reiser complained about small files being stored inefficiently in filesystems.

Today, you can store small files efficiently without wasting much space. What you need is a filesystem with block suballocation, and then create files atomically with open(ANON) write fsync link. It’s a key-value database!

Inspired by this stackoverflow answer.