Re: Move configuration files with pg_upgrade - Mailing list pgsql-general

From Adrian Klaver
Subject Re: Move configuration files with pg_upgrade
Date
Msg-id 0286cb3e-15bd-6577-ad13-bd0d21571565@aklaver.com
Whole thread Raw
In response to Move configuration files with pg_upgrade  (Tanja Savic <tanja.savic@crossmasters.com>)
Responses Re: Move configuration files with pg_upgrade  (Bruce Momjian <bruce@momjian.us>)
List pgsql-general
On 6/4/20 12:52 PM, Tanja Savic wrote:
> Hello,
> 
> I did Postgresql upgrade from v10 to v12 using pg_upgrade (on Linux 
> Ubuntu server).
> Of course i wanted settings inpg_hba.conf and postgresql.conf to keep, 
> but after the upgrade there were new configuration files and I moved it 
> manually.

That is documented:

https://www.postgresql.org/docs/12/pgupgrade.html

"
Restore pg_hba.conf

If you modified pg_hba.conf, restore its original settings. It might 
also be necessary to adjust other configuration files in the new cluster 
to match the old cluster, e.g. postgresql.conf.
"

The new version's conf files  will probably have new settings available 
so this is something that should be reviewed before moving over. One way 
to deal with this is include file(s):

https://www.postgresql.org/docs/12/config-setting.html#CONFIG-INCLUDES

Using them you create the settings you want to manage in the include 
file. Then copy that over and set the include 'some_file' in the new 
postgresql.conf and you are good.

> 
> Is it possible somehow to migrate these old
> configuration files with pg_upgrade or it shall be done manually?
> 
> Cheers,
> Tanja
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com



pgsql-general by date:

Previous
From: "Peter J. Holzer"
Date:
Subject: Re: Move configuration files with pg_upgrade
Next
From: Joe Abbate
Date:
Subject: Binary encoding of TIMESTAMP WITH TIME ZONE