Re: Online verification of checksums - Mailing list pgsql-hackers

From Tomas Vondra
Subject Re: Online verification of checksums
Date
Msg-id 20190328171905.GA16397@development
Whole thread Raw
In response to Re: Online verification of checksums  (Michael Banck <michael.banck@credativ.de>)
Responses Re: Online verification of checksums
List pgsql-hackers
On Thu, Mar 28, 2019 at 05:08:33PM +0100, Michael Banck wrote:
>Hi,
>
>I have rebased this patch now.
>
>I also fixed the two issues Andres reported, namely a zeroed-out
>pageheader and a random LSN. The first is caught be checking for an all-
>zero-page in the way PageIsVerified() does. The second is caught by
>comparing the upper 32 bits of the LSN as well and demanding that they
>are equal. If the LSN is corrupted, the upper 32 bits should be wildly
>different to the current checkpoint LSN.
>
>Well, at least that is a stab at a fix; there is a window where the
>upper 32 bits could legitimately be different. In order to make that as
>small as possible, I update the checkpoint LSN every once in a while.
>

Doesn't that mean we'll report a false positive?

regards

-- 
Tomas Vondra                  http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




pgsql-hackers by date:

Previous
From: Simon Riggs
Date:
Subject: Re: propagating replica identity to partitions
Next
From: Alvaro Herrera
Date:
Subject: Re: partitioned tables referenced by FKs