Re: FSM corruption leading to errors

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: FSM corruption leading to errors
Дата
Msg-id 20161024180655.6pbbpmjjaeunbd2r@alvherre.pgsql
обсуждение исходный текст
Ответ на Re: FSM corruption leading to errors  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: FSM corruption leading to errors  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Tom Lane wrote:

> Ah, scratch that, after rereading the FSM README I see it's correct,
> because there's a binary tree within each page; I'd only remembered
> that there was a search tree of pages.
> 
> Also, we could at least discount the FSM root page and first intermediate
> page, no?  That is, the upper limit could be
> 
>     pg_relation_size(oid::regclass, 'fsm') / 2 - 2*current_setting('block_size')::BIGINT
> 
> I think this is a worthwhile improvement because it reduces the time spent
> on small relations.  For me, the query as given takes 9 seconds to examine
> the regression database, which seems like a lot.  Discounting two pages
> reduces that to 20 ms.

Hah, good one.  We spent some time thinking about subtracting some value
to make the value more accurate but it didn't occur to me to just use
constant two.

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Jonathan Katz
Дата:
Сообщение: Press Release Draft - 2016-10-27 Cumulative Update
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Renaming of pg_xlog and pg_clog