pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedSanity check of shared_buffers value
5+ messages / 3 participants
[nested] [flat]
* Sanity check of shared_buffers value
@ 2023-07-03 19:45 Wells Oliver <wells.oliver@gmail.com>
0 siblings, 1 reply; 5+ messages in thread
From: Wells Oliver @ 2023-07-03 19:45 UTC (permalink / raw)
To: pgsql-admin
Sorry, this is dumb, but I wanted to double check that I'm doing the
shared_buffers calc correctly given it's in 8kb blocks (block_size is set
to 8192).
Want 24GB, which I think is 25165824 KiB so divided by 8 we get 3145728.
Do I have this correct? Usually can test these but wanted to run it by
someone before having to restart the server.
Is there some calc web service out there that idiots such as myself can use
for this?
--
Wells Oliver
wells.oliver@gmail.com <wellsoliver@gmail.com>
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: Sanity check of shared_buffers value
@ 2023-07-03 19:56 Ron <ronljohnsonjr@gmail.com>
parent: Wells Oliver <wells.oliver@gmail.com>
0 siblings, 1 reply; 5+ messages in thread
From: Ron @ 2023-07-03 19:56 UTC (permalink / raw)
To: pgsql-admin@lists.postgresql.org
On 7/3/23 14:45, Wells Oliver wrote:
> Sorry, this is dumb, but I wanted to double check that I'm doing the
> shared_buffers calc correctly given it's in 8kb blocks (block_size is set
> to 8192).
>
> Want 24GB, which I think is 25165824 KiB so divided by 8 we get 3145728.
>
> Do I have this correct? Usually can test these but wanted to run it by
> someone before having to restart the server.
>
> Is there some calc web service out there that idiots such as myself can
> use for this?
https://www.postgresql.org/docs/15/runtime-config-resource.html
"If this value is specified *without **units*, it is taken as blocks,"
My interpretation of this (and what I do in my postgresql.conf file, without
error) is to use a unit name, as such:
shared_buffers = 24GB
--
Born in Arizona, moved to Babylonia.
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: Sanity check of shared_buffers value
@ 2023-07-03 19:57 Wells Oliver <wells.oliver@gmail.com>
parent: Ron <ronljohnsonjr@gmail.com>
0 siblings, 1 reply; 5+ messages in thread
From: Wells Oliver @ 2023-07-03 19:57 UTC (permalink / raw)
To: Ron <ronljohnsonjr@gmail.com>; +Cc: pgsql-admin@lists.postgresql.org
Yeah. Unfortunately in AWS RDS the parameter group settings accept input
only in stricter format, so shared_buffers requires an integer value in KiB.
On Mon, Jul 3, 2023 at 12:56 PM Ron <ronljohnsonjr@gmail.com> wrote:
> On 7/3/23 14:45, Wells Oliver wrote:
>
> Sorry, this is dumb, but I wanted to double check that I'm doing the
> shared_buffers calc correctly given it's in 8kb blocks (block_size is set
> to 8192).
>
> Want 24GB, which I think is 25165824 KiB so divided by 8 we get 3145728.
>
> Do I have this correct? Usually can test these but wanted to run it by
> someone before having to restart the server.
>
> Is there some calc web service out there that idiots such as myself can
> use for this?
>
>
> https://www.postgresql.org/docs/15/runtime-config-resource.html
>
> "If this value is specified *without **units*, it is taken as blocks,"
>
> My interpretation of this (and what I do in my postgresql.conf file,
> without error) is to use a unit name, as such:
> shared_buffers = 24GB
>
> --
> Born in Arizona, moved to Babylonia.
>
--
Wells Oliver
wells.oliver@gmail.com <wellsoliver@gmail.com>
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: Sanity check of shared_buffers value
@ 2023-07-03 20:45 Ron <ronljohnsonjr@gmail.com>
parent: Wells Oliver <wells.oliver@gmail.com>
0 siblings, 1 reply; 5+ messages in thread
From: Ron @ 2023-07-03 20:45 UTC (permalink / raw)
To: pgsql-admin@lists.postgresql.org
Being AWS RDS is the kind of thing you need to mention.
Anyway, plain old bash bc does it for you. Explicitly:
(24*1024^3)/1024/8
Powershell, too:
24*[bigint]::pow(1024,3)/1024/8
On 7/3/23 14:57, Wells Oliver wrote:
> Yeah. Unfortunately in AWS RDS the parameter group settings accept input
> only in stricter format, so shared_buffers requires an integer value in KiB.
>
> On Mon, Jul 3, 2023 at 12:56 PM Ron <ronljohnsonjr@gmail.com> wrote:
>
> On 7/3/23 14:45, Wells Oliver wrote:
>> Sorry, this is dumb, but I wanted to double check that I'm doing the
>> shared_buffers calc correctly given it's in 8kb blocks (block_size is
>> set to 8192).
>>
>> Want 24GB, which I think is 25165824 KiB so divided by 8 we get 3145728.
>>
>> Do I have this correct? Usually can test these but wanted to run it
>> by someone before having to restart the server.
>>
>> Is there some calc web service out there that idiots such as myself
>> can use for this?
>
> https://www.postgresql.org/docs/15/runtime-config-resource.html
>
> "If this value is specified *without **units*, it is taken as blocks,"
>
> My interpretation of this (and what I do in my postgresql.conf file,
> without error) is to use a unit name, as such:
> shared_buffers = 24GB
>
> --
> Born in Arizona, moved to Babylonia.
>
>
>
> --
> Wells Oliver
> wells.oliver@gmail.com <mailto:wellsoliver@gmail.com>
--
Born in Arizona, moved to Babylonia.
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: Sanity check of shared_buffers value
@ 2023-07-05 13:28 jacob ndinkwa <jndinkwa@gmail.com>
parent: Ron <ronljohnsonjr@gmail.com>
0 siblings, 0 replies; 5+ messages in thread
From: jacob ndinkwa @ 2023-07-05 13:28 UTC (permalink / raw)
To: Ron <ronljohnsonjr@gmail.com>; +Cc: pgsql-admin@lists.postgresql.org
You can use:
https://pgtune.leopard.in.ua/
for your cal.
Thanks,
-J
On Mon, Jul 3, 2023 at 4:46 PM Ron <ronljohnsonjr@gmail.com> wrote:
> Being AWS RDS is the kind of thing you need to mention.
>
> Anyway, plain old bash bc does it for you. Explicitly:
> (24*1024^3)/1024/8
>
> Powershell, too:
> 24*[bigint]::pow(1024,3)/1024/8
>
> On 7/3/23 14:57, Wells Oliver wrote:
>
> Yeah. Unfortunately in AWS RDS the parameter group settings accept input
> only in stricter format, so shared_buffers requires an integer value in KiB.
>
> On Mon, Jul 3, 2023 at 12:56 PM Ron <ronljohnsonjr@gmail.com> wrote:
>
>> On 7/3/23 14:45, Wells Oliver wrote:
>>
>> Sorry, this is dumb, but I wanted to double check that I'm doing the
>> shared_buffers calc correctly given it's in 8kb blocks (block_size is set
>> to 8192).
>>
>> Want 24GB, which I think is 25165824 KiB so divided by 8 we get 3145728.
>>
>> Do I have this correct? Usually can test these but wanted to run it by
>> someone before having to restart the server.
>>
>> Is there some calc web service out there that idiots such as myself can
>> use for this?
>>
>>
>> https://www.postgresql.org/docs/15/runtime-config-resource.html
>>
>> "If this value is specified *without **units*, it is taken as blocks,"
>>
>> My interpretation of this (and what I do in my postgresql.conf file,
>> without error) is to use a unit name, as such:
>> shared_buffers = 24GB
>>
>> --
>> Born in Arizona, moved to Babylonia.
>>
>
>
> --
> Wells Oliver
> wells.oliver@gmail.com <wellsoliver@gmail.com>
>
>
> --
> Born in Arizona, moved to Babylonia.
>
^ permalink raw reply [nested|flat] 5+ messages in thread
end of thread, other threads:[~2023-07-05 13:28 UTC | newest]
Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2023-07-03 19:45 Sanity check of shared_buffers value Wells Oliver <wells.oliver@gmail.com>
2023-07-03 19:56 ` Ron <ronljohnsonjr@gmail.com>
2023-07-03 19:57 ` Wells Oliver <wells.oliver@gmail.com>
2023-07-03 20:45 ` Ron <ronljohnsonjr@gmail.com>
2023-07-05 13:28 ` jacob ndinkwa <jndinkwa@gmail.com>
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