pgsql: In WAL replay, restore GIN metapage unconditionally to avoid tor
В списке pgsql-committers по дате отправления:
| От | Heikki Linnakangas |
|---|---|
| Тема | pgsql: In WAL replay, restore GIN metapage unconditionally to avoid tor |
| Дата | |
| Msg-id | E1WNidq-0003YY-65@gemulon.postgresql.org обсуждение исходный текст |
| Список | pgsql-committers |
In WAL replay, restore GIN metapage unconditionally to avoid torn page. We don't take a full-page image of the GIN metapage; instead, the WAL record contains all the information required to reconstruct it from scratch. But to avoid torn page hazards, we must re-initialize it from the WAL record every time, even if it already has a greater LSN, similar to how normal full page images are restored. This was highly unlikely to cause any problems in practice, because the GIN metapage is small. We rely on an update smaller than a 512 byte disk sector to be atomic elsewhere, at least in pg_control. But better safe than sorry, and this would be easy to overlook if more fields are added to the metapage so that it's no longer small. Reported by Noah Misch. Backpatch to all supported versions. Branch ------ REL9_3_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/4738cc3569470f3df8e999080935355d71708c59 Modified Files -------------- src/backend/access/gin/ginxlog.c | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-)
В списке pgsql-committers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера