Re: data checksums - Mailing list pgsql-general

From Christophe Pettus
Subject Re: data checksums
Date
Msg-id CB6A3572-FA73-4EA1-8BD5-F95739BC563C@thebuild.com
Whole thread Raw
In response to Re: data checksums  (Laurenz Albe <laurenz.albe@cybertec.at>)
List pgsql-general

> On Aug 6, 2024, at 19:45, Laurenz Albe <laurenz.albe@cybertec.at> wrote:
> I am surprised by that.  Would you say that most storage systems will happily give you a
> garbage block if there was a hardware problem somewhere?

"Most" is hard for me to judge.  HDDs can have uncorrected and undetected errors, definitely.  ZFS, for example, can
correctthose (within limits); XFS doesn't try.  I have been told that SSDs can have uncorrected/undetected errors as
well,but I don't know details on that. 

> Turning data checksums on will write WAL for hint bits, which can significantly increase
> the amount of WAL written.

I was curious about that, so I just did a quick experiment using pgbench, with identical databases except for
checksums. They both generated the same amount of WAL within 10% or so, so I don't think the impact is huge.  (And you
needthe hint bits for pg_rewind, which is a nice thing to have in your back pocket if required.) 


pgsql-general by date:

Previous
From: Laurenz Albe
Date:
Subject: Re: data checksums
Next
From: Michael Harris
Date:
Subject: ANALYZE on partitioned tables vs on individual partitions