On Fri, Jun 18, 2021 at 1:57 AM Michael Paquier <mich...@paquier.xyz> wrote:

> This doc addition is a bit confusing, as it could mean that each file
> has just one single checksum.  We could be more precise, say:
> "When enabling checksums, each relation file block with a changed
> checksum is rewritten in place."
>

Agreed, I like that wording. New patch attached.


> Should we also mention that the sync happens even if no blocks are
> rewritten based on the reasoning of upthread (aka we'd better do the
> final flush as an interrupted pg_checksums may let a portion of the
> files as not flushed)?
>

I don't know that we need to bother: the default is already to sync and one
has to go out of one's way using the -N argument to NOT sync, so I think
it's a pretty safe assumption to everyone (except those who read my first
version of my patch!) that syncing always happens.

Cheers,
Greg

Attachment: 003.pg_checksums.optimize.writes.and.always.sync.patch
Description: Binary data

Reply via email to