Re: Online verification of checksums

Поиск
Список
Период
Сортировка
От Magnus Hagander
Тема Re: Online verification of checksums
Дата
Msg-id CABUevEyvhjRbcARcd51HPMsVipEvopU-qo9bS21yrryhPvjSyw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Online verification of checksums  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Список pgsql-hackers
On Thu, Aug 30, 2018 at 8:06 PM, Peter Eisentraut <peter.eisentraut@2ndquadrant.com> wrote:
On 26/07/2018 13:59, Michael Banck wrote:
> I've now forward-ported this change to pg_verify_checksums, in order to
> make this application useful for online clusters, see attached patch.

Why not provide this functionality as a server function or command.
Then you can access blocks with proper locks and don't have to do this
rather ad hoc retry logic on concurrent access.

I think it would make sense to provide this functionality in the "checksum worker" infrastruture suggested in the online checksum enabling patch. But I think being able to run it from the outside would also be useful, particularly when it's this simple.

But why do we need a sleep in it? AFAICT this is basically the same code that we have in basebackup.c, and that one does not need the sleep? Certainly 500ms would be very long since we're just protecting against a torn page, but the comment is wrong I think, and we're actually sleeping 0.5ms?

--

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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: BUG #15346: Replica fails to start after the crash
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: Proposal for disk quota feature