Re: Enabling Checksums

Поиск
Список
Период
Сортировка
От Jeff Davis
Тема Re: Enabling Checksums
Дата
Msg-id 1365800557.4736.142.camel@sussancws0025
обсуждение исходный текст
Ответ на Re: Enabling Checksums  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-hackers
On Fri, 2013-04-12 at 15:21 -0400, Bruce Momjian wrote:
> > * When we do PageSetChecksumInplace(), we need to be 100% sure that the
> > hole is empty; otherwise the checksum will fail when we re-expand it. It
> > might be worth a memset beforehand just to be sure.
> 
> Do we write the page holes to the WAL for full-page writes?  I hope we
> don't.

No, but the page hole is included in the checksum.

Let's say that the page hole contains some non-zero value, and we
calculate a checksum. When we eliminate the page hole, and then
reconstitute the page using zeros for the page hole later, then the page
will not match the checksum any more.

So, we need to be sure the original page hole is all-zero when we
calculate the checksum.

Regards,Jeff Davis





В списке pgsql-hackers по дате отправления:

Предыдущее
От: Simon Riggs
Дата:
Сообщение: Re: Enabling Checksums
Следующее
От: Jeff Davis
Дата:
Сообщение: Re: Enabling Checksums