Re: How to calculate shared memory size

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Rébeli-Szabó Tamás <t(at)rblst(dot)info>
Cc: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: How to calculate shared memory size
Date: 2020-09-15 14:49:15
Message-ID: 1293241.1600181355@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

=?UTF-8?Q?R=C3=A9beli-Szab=C3=B3_Tam=C3=A1s?= <t(at)rblst(dot)info> writes:
> I want to do a proper calculation of the number of huge pages needed for
> PostgreSQL to start.
> For that I need to know how much shared memory will be allocated at
> startup.

TBH, the only method that's not going to break over time is
"start the server with the parameters you want, and look to
see how big the shmem segment is".

We used to have an approximate formula in the documentation,
but we took it out years ago because it was constantly out of date.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Magnus Hagander 2020-09-15 17:58:39 Re: multiple tables got corrupted
Previous Message Rébeli-Szabó Tamás 2020-09-15 14:15:14 How to calculate shared memory size