Re: [PATCH] Verify Checksums during Basebackups

Поиск
Список
Период
Сортировка
От Magnus Hagander
Тема Re: [PATCH] Verify Checksums during Basebackups
Дата
Msg-id CABUevEwhFsgmMgniANyC+zXWdH1BC4HoxnotPhS0BRRu+NCsBA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [PATCH] Verify Checksums during Basebackups  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: [PATCH] Verify Checksums during Basebackups  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Tue, Apr 3, 2018 at 4:25 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
Magnus Hagander <magnus@hagander.net> writes:
> Seems the tests are failing on prairiedog:
> https://buildfarm.postgresql.org/cgi-bin/show_stage_log.pl?nm=prairiedog&dt=2018-04-03%2012%3A15%3A27&stg=pg_basebackup-check
> I don't have time to dive in right now, but that seems interesting -- it's
> reporting the failures, but it's then reporting the total number of
> failures as 0...
> Note that prairedog is a PowerPC machine -- I bet that has something to do
> with it.

endianness issue?  I can look closer if you can point me to where to look.

I think the problem comes from:
if (total_checksum_failures > 1)
ereport(WARNING,
(errmsg("%ld total checksum verification failures", total_checksum_failures)));

That one actually logs a zero in the text. Which should not possibly ever pr5int "0 total checksum verification failures".

Unless.. %ld is the wrong thing to print:
static int64 total_checksum_failures;

We should perhaps be using something other than %ld to print that?

--

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [PATCH] Verify Checksums during Basebackups
Следующее
От: Craig Ringer
Дата:
Сообщение: Re: PostgreSQL's handling of fsync() errors is unsafe and risks data loss at least on XFS