Re: CRCs - Mailing list pgsql-hackers

From ncm@zembu.com (Nathan Myers)
Subject Re: CRCs
Date
Msg-id 20010115154527.A571@store.zembu.com
Whole thread Raw
In response to AW: CRCs  (Zeugswetter Andreas SB <ZeugswetterA@wien.spardat.at>)
List pgsql-hackers
Andreas SB Zeugswetter wrote:
> Tom Lane wrote:
> > Instead of a partial row CRC, we could just as well use some other
> > bit of identifying information, say the row OID. ... Checking that
> > there is a valid tuple at the slot indicated by the index item,
> > and that it has the right OID, should be a good enough (and cheap
> > enough) test.
> 
> I would hardly call an additional 4 bytes for OID per index entry
> cheap.

"Cheap enough" is very different from "cheap".  Undetected corruption 
may be arbitrarily expensive when it finally manifests itself.  

That said, maybe storing just the low byte or two of the OID in the 
index would be good enough.  Also, maybe the OID would be there by 
default, but could be ifdef'd out if the size of the indices affects
you noticeably, and you know that your equipment (unlike most) really
does implement strict write ordering.

Nathan Myers
ncm@zembu.com


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Why is LockClassinfoForUpdate()'s mark4update a good idea?
Next
From: Hiroshi Inoue
Date:
Subject: Re: Why is LockClassinfoForUpdate()'s mark4update a good idea?