Re: Using of --data-checksums - Mailing list pgsql-general

From Magnus Hagander
Subject Re: Using of --data-checksums
Date
Msg-id CABUevExHuAV+GNDqU8BY1396T2z7OXy6qE-JhtUy63S-c_KPOw@mail.gmail.com
Whole thread Raw
In response to Re: Using of --data-checksums  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
On Sun, Apr 12, 2020 at 4:23 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
Magnus Hagander <magnus@hagander.net> writes:
> And FWIW, I do think we should change the default. And maybe spend some
> extra effort on the message coming out of pg_upgrade in this case to make
> it clear to people what their options are and exactly what to do.

Is there any hard evidence of checksums catching problems at all?
Let alone in sufficient number to make them be on-by-default?

I would say yes. I've certainly had a fair number of cases where they've detected storage corruption, especially with larger SAN type installation. And coupled with validating the checksum on backup (either with pg_basebackup or pgbackrest) it enables you to find the errors *early*, while you can still restore a previous backup and replay WAL to get to a point where you don't have to lose any data.

I believe both Stephen and David have some good stories they've heard from people catching such issues with backrest as well. 

This and as Michael also points out, it lets you know that the problem occurred outside of PostgreSQL, makes for very important information when tracking down issues.

--

pgsql-general by date:

Previous
From: Anzor Apshev
Date:
Subject: Need for box type with 1/4 precision and gist indexes
Next
From: Virendra Kumar
Date:
Subject: File Foreign Table Doesn't Exist when in Exception