Re: Page Checksums
Stephen Frost <sfrost@snowman.net>
From: Stephen Frost <sfrost@snowman.net>
To: Andres Freund <andres@anarazel.de>
Cc: pgsql-hackers@postgresql.org, Alvaro Herrera <alvherre@commandprompt.com>, Aidan Van Dyk <aidan@highrise.ca>, Josh Berkus <josh@agliodbs.com>
Date: 2011-12-19T17:13:50Z
Lists: pgsql-hackers
* Andres Freund (andres@anarazel.de) wrote: > On Monday, December 19, 2011 03:33:22 PM Alvaro Herrera wrote: > > > I do like the idea of putting the CRC info in a relation fork, if it can > > > be made to work decently, as we might be able to then support it on a > > > per-relation basis, and maybe even avoid the on-disk format change.. > > > > > I think the main objection to that idea was that if you lose a single > > page of CRCs you have hundreds of data pages which no longer have good > > CRCs. > Which I find a pretty non-argument because there is lots of SPOF data in a > cluster (WAL, control record) anyway... > If recent data starts to fail you have to restore from backup anyway. I agree with Andres on this one.. Also, if we use CRC on the pages in the CRC, hopefully we'd be able to detect when a bad block impacted the CRC fork and differentiate that from a whole slew of bad blocks in the heap.. There might be an issue there with handling locking and having to go through the page-level lock on the CRC, which locks a lot more pages in the heap and therefore reduces scalability.. Don't we have a similar issue with the visibility map though? Thanks, Stephen