Re: Lessons from using mmap()

From: Alexander Korotkov <aekorotkov(at)gmail(dot)com>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Lessons from using mmap()
Date: 2024-02-20 23:58:50
Message-ID: CAPpHfdtFuwHgL8MEq1CH6xdjiBoG-Wd5e9q-wBQYP3JYxJE7kA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi!

On Wed, Feb 21, 2024 at 1:21 AM Bruce Momjian <bruce(at)momjian(dot)us> wrote:
> I think we have come to the same conclusion in the past, but I thought
> it would be good to share someone else's research, and it might be
> helpful if we ever revisit this idea.

I read this blog post before. In my personal opinion it is an example
of awful speculation. If your DBMS needs WAL, then your first
question about using mmap() for your data is how to enforce WAL to be
really ahead of writing the data pages. As I know there is no
solution for that with mmap() (or at least a solution with acceptable
portability). The blog post advertises LMDB, and LMDB is really good.
But LMDB uses copy-on-write instead of WAL to ensure durability. And
it supports a single writer at a time. This is just another niche of
solutions!
The blog post makes an impression that developers of non-mmap()
DBMS'es are idiots who didn't manage to use mmap() properly. We're
not idiots, we develop DBMS of high concurrency! :-)

------
Regards,
Alexander Korotkov

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Alexander Korotkov 2024-02-21 00:51:20 Re: partitioning and identity column
Previous Message David Rowley 2024-02-20 23:48:13 Re: Add bump memory context type and use it for tuplesorts