Re: postgresql meltdown on PlanetMath.org

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: postgresql meltdown on PlanetMath.org
Дата
Msg-id 10490.1048227512@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: postgresql meltdown on PlanetMath.org  (Florian Weimer <Weimer@CERT.Uni-Stuttgart.DE>)
Список pgsql-performance
Florian Weimer <Weimer@CERT.Uni-Stuttgart.DE> writes:
> Hmm, are there any guidelines for choosing these values?

> We have a database with a table into which we insert about 4,000,000
> rows each day, and delete another 4,000,000 rows.  The total row count
> is around 40 million, I guess, and the rows are about 150 bytes long.

If you are replacing 10% of the rows in the table every day, then it's
a pretty good bet that every single page of the table contains free
space.  Accordingly, you'd better set max_fsm_pages large enough to
have a FSM slot for every page of the table.  (1 page = 8Kb normally)

You could possibly get away with a smaller FSM if you do (non-FULL)
vacuums more often than once a day.  Some people find they can run
background vacuums without hurting performance too much, some don't
--- I suspect it depends on how much spare disk bandwidth you have.

            regards, tom lane

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

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Re: Page Size in Future Releases
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Page Size in Future Releases