Re: Changing WAL Header to reduce contention duringReserveXLogInsertLocation()

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: Changing WAL Header to reduce contention duringReserveXLogInsertLocation()
Дата
Msg-id 20180112215858.4xqa45fvi3w45as2@alap3.anarazel.de
обсуждение исходный текст
Ответ на Re: Changing WAL Header to reduce contention during ReserveXLogInsertLocation()  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Changing WAL Header to reduce contention during ReserveXLogInsertLocation()
Список pgsql-hackers
On 2018-01-12 10:45:54 -0500, Tom Lane wrote:
> Robert Haas <robertmhaas@gmail.com> writes:
> > On Sat, Dec 30, 2017 at 5:32 AM, Simon Riggs <simon@2ndquadrant.com> wrote:
> > I have some reservations about whether this makes the mechanism less
> > reliable.
> 
> Yeah, it scares me too.

Same here.


> The xl_prev field is our only way of detecting that we're looking at
> old WAL data when we cross a sector boundary.

Right. I wonder if it be reasonable to move that to a page's header
instead of individual records?  To avoid torn page issues we'd have to
reduce the page size to a sector size, but I'm not sure that's that bad?


> > Of course, we also have xl_crc, so I'm not sure whether there's any
> > chance of real harm...
> 
> The CRC only tells you that you have a valid WAL record, it won't clue
> you in that it's old data you shouldn't replay.

Yea, I don't like relying on the CRC alone at all.

Greetings,

Andres Freund


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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: WIP: a way forward on bootstrap data
Следующее
От: Tom Lane
Дата:
Сообщение: Re: WIP: a way forward on bootstrap data