Re: PGSQL 11.4: shared_buffers and /dev/shm size

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: PGSQL 11.4: shared_buffers and /dev/shm size
Дата
Msg-id CA+hUKGJOj7qzDLxeFPVvto8YEWop6FSQoTYPO9Z6Ee=i-nPS_Q@mail.gmail.com
обсуждение исходный текст
Ответ на Re: PGSQL 11.4: shared_buffers and /dev/shm size  (Jean Louis <bugs@gnu.support>)
Ответы Re: PGSQL 11.4: shared_buffers and /dev/shm size  (Konstantin Malanchev <hombit@gmail.com>)
Список pgsql-general
On Tue, Jul 9, 2019 at 10:15 PM Jean Louis <bugs@gnu.support> wrote:
> * Konstantin Malanchev <hombit@gmail.com> [2019-07-09 12:10]:
> > I have 8 GB RAM and /dev/shm size is 4GB, and there is no significant memory usage by other system processes. I
surprisedthat Postgres uses more space in /dev/shm than sharred_buffers parameter allows, probably I don't understand
whatthis parameter means. 
> >
> > I have no opportunity to enlarge total RAM and probably this query requires too much RAM to execute. Should
Postgresjust use HDD as temporary storage in this case? 
>
> That I cannot know. I know that /dev/shm could
> grow as much as available free RAM.

Hi,

PostgreSQL creates segments in /dev/shm for parallel queries (via
shm_open()), not for shared buffers.  The amount used is controlled by
work_mem.  Queries can use up to work_mem for each node you see in the
EXPLAIN plan, and for each process, so it can be quite a lot if you
have lots of parallel worker processes and/or lots of
tables/partitions being sorted or hashed in your query.

--
Thomas Munro
https://enterprisedb.com



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

Предыдущее
От: Jean Louis
Дата:
Сообщение: Re: PGSQL 11.4: shared_buffers and /dev/shm size
Следующее
От: Konstantin Malanchev
Дата:
Сообщение: Re: PGSQL 11.4: shared_buffers and /dev/shm size