Re: bgwriter, regression tests, and default shared_buffers settings

Поиск
Список
Период
Сортировка
От Amit Kapila
Тема Re: bgwriter, regression tests, and default shared_buffers settings
Дата
Msg-id 000e01cd6570$0d93b960$28bb2c20$@kapila@huawei.com
обсуждение исходный текст
Ответ на bgwriter, regression tests, and default shared_buffers settings  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
> From: pgsql-hackers-owner@postgresql.org
[mailto:pgsql-hackers-owner@postgresql.org] 
> On Behalf Of Tom Lane

> So that raises two independent sets of questions:

> 1. Do we like the fact that the bgwriter isn't doing anything in this
> situation?  It seems arguably OK for writes to happen only for
> checkpointing purposes if there is no memory pressure.  But having the
> bgwriter wake up 5 times a second to decide it has nothing to do seems
> a bit wasteful.  I'm inclined to think maybe it should go into the
> recently added "hibernation mode" anytime the buffer freelist isn't
> empty.  Or maybe you could argue that this scenario isn't worth any
> optimization effort, but with many-gig RAM becoming more and more
> common, I don't think I agree.

I also believe it should go to "hibernation mode" if the freelist is not
exhanusted or even it could be when freelist is less than (50% some
threshold number) used.
I have one doubt regarding this approach. According to above, what I
understood is after going to hibernation ideally it should get wakeup either
at timeout or when freelist is exhausted.
However current code wakes up before ensuring whether the buffer allocation
can be done from freelist.  

With Regards,
Amit Kapila.




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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: b-tree index search algorithms
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Using pg_upgrade on log-shipping standby servers