Re: Updating FSM on recovery

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: Updating FSM on recovery
Дата
Msg-id 1225208150.3971.191.camel@ebony.2ndQuadrant
обсуждение исходный текст
Ответ на Updating FSM on recovery  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Ответы Re: Updating FSM on recovery  (Simon Riggs <simon@2ndQuadrant.com>)
Re: Updating FSM on recovery  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Список pgsql-hackers
On Tue, 2008-10-28 at 16:22 +0200, Heikki Linnakangas wrote:

> Arbitrarily, if after a 
> heap insert/update there's less than 20% of free space on the page,
> the FSM is updated. Compared to updating it every time, that saves a
> lot of overhead, while doing a pretty good job at marking full pages
> as full in  the FSM. My first thought was to update the FSM if there
> isn't enough room on the page for a new tuple of the same size as the
> one just 
> inserted; that would be pretty close to the logic we have during
> normal 
> operation, where the FSM is updated when the tuple that we're about
> to 
> insert doesn't fit on the page. But because we don't know the
> fillfactor 
> during recovery, I don't think we can do reliably.

With HOT, we tend to hover around the nearly-full state, so this seems
like it will trigger repeatedly.

Is it possible that we could put an extra field onto a heap_clean record
to show remaining space. We would use it only for VACUUMs, not HOT, just
as we do now.

Probably good idea to make a list of user cases and say what we do in
eahc case. e.g. COPY, other bulk ops, HOT etc..

I wonder if there is merit in having an XLogInsertMulti() which inserts
multiple records in a batch as a way of reducing WALInsertLock traffic.
It might be possible to piggyback FSM records onto the main heap
changes.

-- Simon Riggs           www.2ndQuadrant.comPostgreSQL Training, Services and Support



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

Предыдущее
От: "postgres Emanuel CALVO FRANCO"
Дата:
Сообщение: FAQ_Solaris 1.28 to spanish
Следующее
От: "Pavel Stehule"
Дата:
Сообщение: Re: WIP patch: convert SQL-language functions to return tuplestores