Skip to content
Snippets Groups Projects
Commit 9cef05e0 authored by Noah Misch's avatar Noah Misch
Browse files

Limit pg_upgrade authentication advice to always-secure techniques.

~/.pgpass is a sound choice everywhere, and "peer" authentication is
safe on every platform it supports.  Cease to recommend "trust"
authentication, the safety of which is deeply configuration-specific.
Back-patch to 9.0, where pg_upgrade was introduced.
parent a223b9e3
Branches
Tags
No related merge requests found
...@@ -280,10 +280,9 @@ gmake prefix=/usr/local/pgsql.new install ...@@ -280,10 +280,9 @@ gmake prefix=/usr/local/pgsql.new install
<title>Adjust authentication</title> <title>Adjust authentication</title>
<para> <para>
<command>pg_upgrade</> will connect to the old and new servers several times, <command>pg_upgrade</> will connect to the old and new servers several
so you might want to set authentication to <literal>trust</> times, so you might want to set authentication to <literal>peer</>
or <literal>peer</> in <filename>pg_hba.conf</>, or if using in <filename>pg_hba.conf</> or use a <filename>~/.pgpass</> file
<literal>md5</> authentication, use a <filename>~/.pgpass</> file
(see <xref linkend="libpq-pgpass">). (see <xref linkend="libpq-pgpass">).
</para> </para>
</step> </step>
...@@ -390,10 +389,9 @@ pg_upgrade.exe ...@@ -390,10 +389,9 @@ pg_upgrade.exe
<title>Restore <filename>pg_hba.conf</></title> <title>Restore <filename>pg_hba.conf</></title>
<para> <para>
If you modified <filename>pg_hba.conf</> to use <literal>trust</>, If you modified <filename>pg_hba.conf</>, restore its original settings.
restore its original authentication settings. It might also be It might also be necessary to adjust other configuration files in the new
necessary to adjust other configurations files in the new cluster to cluster to match the old cluster, e.g. <filename>postgresql.conf</>.
match the old cluster, e.g. <filename>postgresql.conf</>.
</para> </para>
</step> </step>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment