Re: pg_upgrade: can I use same binary for old & new?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Pierre Fortin <pf(at)pfortin(dot)com>
Cc: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: pg_upgrade: can I use same binary for old & new?
Date: 2025-07-05 19:27:33
Message-ID: 70968.1751743653@sss.pgh.pa.us
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-general

Pierre Fortin <pf(at)pfortin(dot)com> writes:
> OK... I failed to mention I have several databases in this cluster; so
> digging into pg_dumpall, I see:
> --binary-upgrade
> This option is for use by in-place upgrade utilities. Its use for
> other purposes is not recommended or supported. The behavior of the
> option may change in future releases without notice.

That is infrastructure for pg_upgrade to use. Do not try to use it
manually; it won't end well.

> All my DBs are static (only queries once loaded). Assuming the dumpall
> file fits on one of my drives:
> pg_dumpall -f <path>/PG.backup -v
> appears to be all I need? pg_dump has compression by default; but I don't
> see compression with dumpall other than for TOAST.

I would try that first before messing with compression. If it doesn't
fit, you'll need to do pg_dumpall --globals-only (mainly to capture
your role definitions) and then pg_dump each database into a separate
compressed file.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Ron Johnson 2025-07-05 19:29:03 Re: pg_upgrade: can I use same binary for old & new?
Previous Message Pierre Fortin 2025-07-05 19:19:28 Re: pg_upgrade: can I use same binary for old & new?