Re: Why is checkpoint so costly?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Why is checkpoint so costly?
Дата
Msg-id 20799.1119470376@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Why is checkpoint so costly?  (Greg Stark <gsstark@mit.edu>)
Список pgsql-hackers
Greg Stark <gsstark@mit.edu> writes:
> The question should be why is there any time when a checkpoint *isn't*
> happening? For maximum performance the combination of bgwriter (basically
> preemptive checkpoint i/o) and the actual checkpoint i/o should be executing
> at a more or less even pace throughout the time interval between checkpoints.

I think Josh's complaint has to do with the fact that performance
remains visibly affected after the checkpoint is over.  (It'd be nice
if those TPM graphs could be marked with the actual checkpoint begin
and end instants, so we could confirm or deny that we are looking at a
post-checkpoint recovery curve and not some very weird behavior inside
the checkpoint.)  It's certainly true that tuning the bgwriter ought to
help in reducing the amount of I/O done by a checkpoint, but why is
there a persistent effect?

> That said, does checkpointing (and bgwriter i/o) require rereading the WAL
> logs?

No.  In fact, the WAL is never read at all, except during actual
post-crash recovery.
        regards, tom lane


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [PATCHES] O_DIRECT for WAL writes
Следующее
От: Greg Stark
Дата:
Сообщение: Re: commit_delay, siblings