Re: Default wal_sync_method on FreeBSD

From: Thomas Munro <thomas(dot)munro(at)gmail(dot)com>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Default wal_sync_method on FreeBSD
Date: 2021-02-15 03:28:08
Message-ID: CA+hUKG+z5hkmvFSA-9e7Xi8Gv4+uhxMMaU4-dXJ-iOtD9fZ9NA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jan 8, 2021 at 2:19 PM Thomas Munro <thomas(dot)munro(at)gmail(dot)com> wrote:
> The system header change has one interesting consequence for existing
> releases of PostgreSQL, though: xlogdefs.h now sees that there is an
> O_DSYNC macro that is distinct from O_SYNC, and defaults to
> wal_sync_method=open_datasync. That's not a great default setting,
> because it gets you O_DIRECT | O_DSYNC, which performs terribly when
> you're writing 8KB blocks on UFS's default 32KB logical block size (it
> triggers read-before-write, quite visibly destroying performance with
> eg pg_test_fsync), and for all I know, it might even not work at all
> on some other file systems. I suspect it might come out very slightly
> ahead on a UFS filesystem created with 8KB blocks, but in any case,
> that seems like something you should have to opt in to, as you do on
> Linux.

Done.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2021-02-15 03:54:13 Re: repeated decoding of prepared transactions
Previous Message Seamus Abshere 2021-02-15 03:15:04 A reloption for partitioned tables - parallel_workers