Re: PITR, checkpoint, and local relations

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: PITR, checkpoint, and local relations
Дата
Msg-id 29568.1028296896@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: PITR, checkpoint, and local relations  ("J. R. Nield" <jrnield@usol.com>)
Ответы Re: PITR, checkpoint, and local relations
Список pgsql-hackers
"J. R. Nield" <jrnield@usol.com> writes:
> Ok. This is what I wanted to hear, but I had assumed someone decided to
> put it in for a reason, and I wasn't going to submit a patch to pull-out
> the local buffer manager without clearing it first.

> The main area where it seems to get heavy use is during index builds,

Yeah.  I do not think it really saves any I/O: unless you abort your
index build, the data is eventually going to end up on disk anyway.
What it saves is contention for shared buffers (the overhead of
acquiring BufMgrLock, for example).

Just out of curiosity, though, what does it matter?  On re-reading your
message I think you are dealing with a non problem, or at least the
wrong problem.  Local relations do not need to be checkpointed, because
by definition they were created by a transaction that hasn't committed
yet.  They must be, and are, checkpointed to disk before the transaction
commits; but up till that time, if you have a crash then the entire
relation should just go away.

That mechanism is there already --- perhaps it needs a few tweaks for
PITR but I do not see any need for cross-backend flush commands for
local relations.
        regards, tom lane


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

Предыдущее
От: cbbrowne@cbbrowne.com
Дата:
Сообщение: Third Manifesto
Следующее
От: Greg Copeland
Дата:
Сообщение: Re: Why is MySQL more chosen over PostgreSQL?