NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: NetBSD on a database server - WAPBL, softdeps

"Steven M. Bellovin" <> wrote:
> The issue Thor is pointing out is the granularity of recovery.  WAPBL
> and fsck use file-level granularity -- they ensure the consistency of
> the *file system*.  Databases have their own, complex internal
> structure; WAPBL and fsck know nothing of them.  If you want
> consistency, you have to ensure that the important blocks are written
> out in the proper order.  It's reasonable to want the database to do
> that; it is not reasonable to expect the system to.

Yes, for example, PostgreSQL has WAL.  Theoretically, database transaction
log does not need an additional file-system journal.  However, my point
was not about the consistency - it was about recovery time.

> I think the system call you should be concerned about is
> fsync_range().  Is that used (properly) by your database?  Is it fast
> enough?

No, AFAIK databases use fsync() (maybe DB2 uses fsync_range?), although
it depends at some level.  You can change WAL sync method in PostgreSQL,
as well as tune data/commit synchronisation behaviour in most databases.


Home | Main Index | Thread Index | Old Index