pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Konstantin Malanchev <hombit@gmail.com>
To: pgsql-general@postgresql.org
Subject: PGSQL 11.4: shared_buffers and /dev/shm size
Date: Tue, 9 Jul 2019 12:50:31 +0300
Message-ID: <7E4D7DA4-E093-4F6A-AE8E-81A73B995A8D@gmail.com> (raw)

Hello,

I'm running PostgreSQL 11.4 on Linux 4.12.14 and I see the following issue while executing single one query:
ERROR:  could not resize shared
memory segment "/PostgreSQL.1596105766" to 536870912 bytes: No space left on device

In my postgresql.conf I set sharred_buffers=256MB, I see that it is applied:
SHOW shared_buffers;
 shared_buffers
----------------
 256MB

At the same time during the query execution, I see a lot of files in /dev/shm with the total size more than 256MB

ls -lh /dev/shm
total 1.4G
-rw------- 1 postgres postgres 193K Jul  8 08:39 PostgreSQL.1026343462
-rw------- 1 postgres postgres 4.0M Jul  8 10:23 PostgreSQL.1066463809
-rw------- 1 postgres postgres 8.0M Jul  8 10:23 PostgreSQL.1154587693
-rw------- 1 postgres postgres 4.0M Jul  8 08:47 PostgreSQL.1292794952
-rw------- 1 postgres postgres 128M Jul  8 10:23 PostgreSQL.130026740
-rw------- 1 postgres postgres 8.0M Jul  8 10:23 PostgreSQL.1377271816
-rw------- 1 postgres postgres  16M Jul  8 10:23 PostgreSQL.1453162423
-rw------- 1 postgres postgres 128M Jul  8 10:23 PostgreSQL.1496397787
-rw------- 1 postgres postgres 8.0M Jul  8 10:23 PostgreSQL.1541518903
-rw------- 1 postgres postgres  64M Jul  8 10:23 PostgreSQL.1554139410
-rw------- 1 postgres postgres 2.0M Jul  8 10:23 PostgreSQL.1563273542
-rw------- 1 postgres postgres 256M Jul  8 10:23 PostgreSQL.1604524364
-rw------- 1 postgres postgres  64M Jul  8 10:23 PostgreSQL.1624127960
-rw------- 1 postgres postgres 4.0M Jul  8 10:23 PostgreSQL.1674892421
-rw------- 1 postgres postgres 128M Jul  8 10:32 PostgreSQL.179085785
-rw------- 1 postgres postgres  32M Jul  8 10:23 PostgreSQL.1921401343
-rw------- 1 postgres postgres  32M Jul  8 10:23 PostgreSQL.1931571650
-rw------- 1 postgres postgres 2.0M Jul  8 10:23 PostgreSQL.2002232858
-rw------- 1 postgres postgres 2.0M Jul  8 10:23 PostgreSQL.2057901523
-rw------- 1 postgres postgres 2.0M Jul  8 10:23 PostgreSQL.2110310896
-rw------- 1 postgres postgres  65M Jul  8 08:39 PostgreSQL.2136390898
-rw------- 1 postgres postgres 182K Jul  8 08:39 PostgreSQL.261370809
-rw------- 1 postgres postgres  16M Jul  8 10:23 PostgreSQL.397419407
-rw------- 1 postgres postgres 4.0M Jul  8 10:23 PostgreSQL.431734656
-rw------- 1 postgres postgres 128M Jul  8 10:23 PostgreSQL.478359814
-rw------- 1 postgres postgres 8.0M Jul  8 10:23 PostgreSQL.489042863
-rw------- 1 postgres postgres  64M Jul  8 10:23 PostgreSQL.590987495
-rw------- 1 postgres postgres 3.4M Jul  8 08:39 PostgreSQL.62466476
-rw------- 1 postgres postgres  16M Jul  8 10:23 PostgreSQL.629400316
-rw------- 1 postgres postgres 6.8K Jul  8 08:39 PostgreSQL.741718396
-rw------- 1 postgres postgres  16M Jul  8 10:23 PostgreSQL.770970033
-rw------- 1 postgres postgres 1.0M Jul  8 10:23 PostgreSQL.776045115
-rw------- 1 postgres postgres  64M Jul  8 10:23 PostgreSQL.795742467
-rw------- 1 postgres postgres  32M Jul  8 10:23 PostgreSQL.835134775
-rw------- 1 postgres postgres  32M Jul  8 10:23 PostgreSQL.953710812

How can I configure limit for total shared memory size?


Best regards,
Konstantin




view thread (10+ messages)  latest in thread

Message-ID: <7E4D7DA4-E093-4F6A-AE8E-81A73B995A8D@gmail.com>
Permalink:  ../7E4D7DA4-E093-4F6A-AE8E-81A73B995A8D@gmail.com/
Also on:    postgresql.org/message-id/7E4D7DA4-E093-4F6A-AE8E-81A73B995A8D@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: hombit@gmail.com
  Subject: Re: PGSQL 11.4: shared_buffers and /dev/shm size
  In-Reply-To: <7E4D7DA4-E093-4F6A-AE8E-81A73B995A8D@gmail.com>
  References: <7E4D7DA4-E093-4F6A-AE8E-81A73B995A8D@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox