rewriteheap.c bug: toast rows don't get XIDs matching their parents

Поиск
Список
Период
Сортировка
От Tom Lane
Тема rewriteheap.c bug: toast rows don't get XIDs matching their parents
Дата
Msg-id 16465.1326405058@sss.pgh.pa.us
обсуждение исходный текст
Ответы Re: rewriteheap.c bug: toast rows don't get XIDs matching their parents  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
While working on bug #6393 I was reminded of the truth of $SUBJECT: any
rows inserted into the new toast table will have the xmin of the CLUSTER
or VACUUM FULL operation, and invalid xmax, whereas their parent heap
rows will have xmin/xmax copied from the previous instance of the table.
This does not matter much for ordinary live heap rows, but it's also
necessary for CLUSTER/VACUUM FULL to copy recently-dead,
insert-in-progress, and delete-in-progress rows.  In such cases, a later
plain VACUUM might reap the parent heap rows and not the toast rows,
leading to a storage leak that won't be recovered short of another
CLUSTER/VACUUM FULL.

I can't remember if we discussed this risk when the heap rewrite code
was written.  I'm not sure it's worth fixing, but at the least it ought
to be documented in the comments in rewriteheap.c.
        regards, tom lane


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

Предыдущее
От: Thomas Munro
Дата:
Сообщение: Re: WIP -- renaming implicit sequences
Следующее
От: Simon Riggs
Дата:
Сообщение: ERRCODE_READ_ONLY_SQL_TRANSACTION