Re: upgrade questions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 09.02.24 um 18:07 schrieb Scott Ribe:
On Feb 9, 2024, at 10:00 AM, David Barron <david.barron@xxxxxxxxxx> wrote:

I’ve also seen references to copying over the pg_hba.conf and postgresql.conf files from the old data directory to the new.
Then you will be getting default values for the many, many parameters added to postgresql.conf between 11 & 15--and will have no explanatory entries documenting them. A much better suggestion is to diff the two, and apply customizations from the old to the new. (Also skim release notes for any that have been mooted.)

Scott is right. Copying an old postgresql.conf over a new one is a terrible idea.

There is the general advice to never make changes to postgresql.conf (except activating the include_dir instruction close to the end of the file).

include_dir = 'conf.d'            # include files ending in '.conf' from
                    # a directory, e.g., 'conf.d'

Some distributions have this only as a comment, so remove the # at the beginning of the line and don't forget to at least create the directory conf.d, because some distribution packages don't create it.

ALL changes to the configuration should go into files within this directory having names ending in .conf

If you have these, it's very easy to copy them over to a new cluster (same or newer major version) and adapt if necessary.

It's best to copy sections from the original postgresql.conf including all comments and make necessary changes only within the conf.d directory.

Regards,

Holger


-- 
Holger Jakobs, Bergisch Gladbach, Tel. +49-178-9759012

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


[Index of Archives]     [Postgresql Home]     [Postgresql General]     [Postgresql Performance]     [Postgresql PHP]     [Postgresql Jobs]     [PHP Users]     [PHP Databases]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Forum]

  Powered by Linux