Re: WAL & SHM principles - Mailing list pgsql-hackers

From Matthew Kirkwood
Subject Re: WAL & SHM principles
Date
Msg-id Pine.LNX.4.10.10103132142010.27908-100000@sphinx.mythic-beasts.com
Whole thread Raw
In response to Re: WAL & SHM principles  (Alfred Perlstein <bright@wintelcom.net>)
List pgsql-hackers
On Tue, 13 Mar 2001, Alfred Perlstein wrote:

[..]
> Linux does not filesystem-sync file-backed writable mmap pages on a
> regular basis.

Very intersting.  I'm not sure that is necessarily the case in
2.4, though -- my understanding is that the new all-singing,
all-dancing page cache makes very little distinction between
mapped and unmapped dirty pages.

> Basically any mmap'd data doesn't seem to get sync()'d out on
> a regular basis.

Hmm.. I'd call that a bug, anyway.

> > > and this is used as a security feature for cryptography software.
> >
> > mlock() is used to prevent pages being swapped out.  Its
> > use for crypto software is essentially restricted to anon
> > memory (allocated via brk() or mmap() of /dev/zero).
>
> What about userland device drivers that want to send parts
> of a disk backed file to a driver's dma routine?

And realtime software.  I'm not disputing that mlock is useful,
but what it can do be security software is not that huge.  The
Linux manpage says:
      Memory locking has two main applications: real-time  algo­      rithms and high-security data processing.

Matthew.



pgsql-hackers by date:

Previous
From: Alfred Perlstein
Date:
Subject: Re: Performance monitor signal handler
Next
From: Thomas Lockhart
Date:
Subject: Re: xlog loose ends, continued