Re: bgwriter changes

Поиск
Список
Период
Сортировка
От Jan Wieck
Тема Re: bgwriter changes
Дата
Msg-id 41C06D5D.5050608@Yahoo.com
обсуждение исходный текст
Ответ на Re: bgwriter changes  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: bgwriter changes
Список pgsql-hackers
On 12/14/2004 2:40 PM, Tom Lane wrote:

> "Zeugswetter Andreas DAZ SD" <ZeugswetterA@spardat.at> writes:
>> Is it possible to do a patch that produces a dirty buffer list in LRU order
>> and stops early when eighter maxpages is reached or bgwriter_percent
>> pages are scanned ?
> 
> Only if you redefine the meaning of bgwriter_percent.  At present it's
> defined by reference to the total number of dirty pages, and that can't
> be known without collecting them all.
> 
> If it were, say, a percentage of the total length of the T1/T2 lists,
> then we'd have some chance of stopping the scan early.

That definition is identical to a fixed maximum number of pages to write 
per call. And since that parameter exists too, it would be redundant.

The other way around would make sense. In order to avoid writing the 
busiest buffers at all (except for checkpoinging), the parameter should 
mean "don't scan the last x% of the queue at all".

Still, we need to avoid scanning over all the clean blocks of a large 
buffer pool, so there is need for a separate dirty-LRU.


Jan

-- 
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#================================================== JanWieck@Yahoo.com #


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

Предыдущее
От: Joe Conway
Дата:
Сообщение: Re: production server down
Следующее
От: Tom Lane
Дата:
Сообщение: Re: production server down