Re: Kernel cache vs shared_buffers

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: Kernel cache vs shared_buffers
Дата
Msg-id 4645CF1D.1030309@enterprisedb.com
обсуждение исходный текст
Ответ на Kernel cache vs shared_buffers  ("Michael van Rooyen" <mvanr@bigfoot.com>)
Ответы Re: Kernel cache vs shared_buffers  ("Jim C. Nasby" <jim@nasby.net>)
Re: Kernel cache vs shared_buffers  ("Harald Armin Massa" <haraldarminmassa@gmail.com>)
Список pgsql-performance
Michael van Rooyen wrote:
> I have no idea regarding the inner working of the pg's shared cache, but
> what I would like to find out is whether it is table-row-based, or
> disk-block-based.

It's block based.

> In the case of it being disk-block based, my
> inclination would be to let the kernel do the buffering.  In the case of
> the cache being table-row-based, I would expect it to be much more
> space-efficient and I would be inclined to give the memory to the pg.
> In that case, is it feasible to set shared_buffers to something like
> 500000 x 8k blocks?  We make extensive use of indexes on the larger
> tables and would seldom, if ever, do sequential scans.

A common rule of thumb people quote here is to set shared_buffers to 1/4
of available RAM, and leave the rest for OS cache. That's probably a
good configuration to start with.

--
   Heikki Linnakangas
   EnterpriseDB   http://www.enterprisedb.com

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

Предыдущее
От: "Michael van Rooyen"
Дата:
Сообщение: Kernel cache vs shared_buffers
Следующее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: estimating the need for VACUUM FULL and REINDEX