Enable data checksums by default - Mailing list pgsql-hackers

From Christoph Berg
Subject Enable data checksums by default
Date
Msg-id 20190322151653.GD32388@msg.df7cb.de
Whole thread Raw
Responses Re: Enable data checksums by default
Re: Enable data checksums by default
List pgsql-hackers
Lately, PostgreSQL has moved many defaults from "bare minimum" more to
the "user friendly by default" side, e.g. hot_standby & replication in
the default configuration, parallelism, and generally higher defaults
for resource knobs like *_mem, autovacuum_* and so on.

I think, the next step in that direction would be to enable data
checksums by default. They make sense in most setups, and people who
plan to run very performance-critical systems where checksums might be
too much need to tune many knobs anyway, and can as well choose to
disable them manually, instead of having everyone else have to enable
them manually. Also, disabling is much easier than enabling.

One argument against checksums used to be that we lack tools to fix
problems with them. But ignore_checksum_failure and the pg_checksums
tool fix that.

The attached patch flips the default in initdb. It also adds a new
option -k --no-data-checksums that wasn't present previously. Docs are
updated to say what the new default is, and the testsuite exercises
the -K option.

Christoph

Attachment

pgsql-hackers by date:

Previous
From: David Rowley
Date:
Subject: Re: Removing unneeded self joins
Next
From: Peter Eisentraut
Date:
Subject: Re: pg_basebackup ignores the existing data directory permissions