Re: [Patch] change the default value of shared_buffers in postgresql.conf.sample - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [Patch] change the default value of shared_buffers in postgresql.conf.sample
Date
Msg-id 2648985.1624549772@sss.pgh.pa.us
Whole thread Raw
In response to [Patch] change the default value of shared_buffers in postgresql.conf.sample  ("zhangjie2@fujitsu.com" <zhangjie2@fujitsu.com>)
Responses Re: [Patch] change the default value of shared_buffers in postgresql.conf.sample  (Daniel Gustafsson <daniel@yesql.se>)
RE: [Patch] change the default value of shared_buffers in postgresql.conf.sample  ("zhangjie2@fujitsu.com" <zhangjie2@fujitsu.com>)
Re: [Patch] change the default value of shared_buffers in postgresql.conf.sample  (Magnus Hagander <magnus@hagander.net>)
List pgsql-hackers
"zhangjie2@fujitsu.com" <zhangjie2@fujitsu.com> writes:
> In PostgreSQL 14, The default value of shared_buffers is 128MB, but in postgresql.conf.sample, the default value of
shared_buffersis 32MB. 
> I think the following changes should be made.

> File: postgresql\src\backend\utils\misc\ postgresql.conf.sample
> #shared_buffers = 32MB  =>  #shared_buffers = 128MB

As submitted, this patch breaks initdb, which is looking for the exact
string "#shared_buffers = 32MB".

We could adjust that too of course, but I'm dubious first that any
change is needed, and second that this is the right one:

1. Since initdb will replace that string, users will never see this
entry as-is in live databases.  So is it worth doing anything?

2. The *actual*, hard-wired, default in guc.c is 1024 (8MB), not
either of these numbers.  So maybe the sample file ought to use
that instead.  Or maybe we should change that value too ... it's
surely as obsolete as can be.

On the whole this seems pretty cosmetic so I'm inclined to leave
it alone.  But if we were going to do anything I think that
adjusting both initdb.c and guc.c to use 128MB might be the
most appropriate thing.

            regards, tom lane



pgsql-hackers by date:

Previous
From: John Naylor
Date:
Subject: Re: a path towards replacing GEQO with something better
Next
From: Alvaro Herrera
Date:
Subject: Re: Pipeline mode and PQpipelineSync()