On Tue, 15 Sep 2026, Alban Hertroys wrote:
> If you’re dumping one database at a time, that doesn’t include any of the
> database roles or users you may have added. Roles (and users) are stored
> with the cluster, not per database.
>
> That’s where the below mentioned `pg_dumpall --globals-only` feature comes
> into play. You don’t need the parallel stuff, but the globals bit could be
> important.
>
> With the rest cut out, that leaves:
>
>>
>>> Current system:
>>> cd /path/to/backups
>>> pg_dumpall --globals-only > globals_127.sql
>
> ...
>
>>> New system:
>>> cd /path/to/backups
>>> psql -af globals_127.sql
Alban,
I was not aware of this because in the past all version upgrades were on the
same host.
A valuable lesson. Thanks very much.
Regards,
Rich