From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | Yuri Niyazov <yuri(at)academia(dot)edu>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: pg_upgrade documentation improvement patch |
Date: | 2016-04-13 12:29:25 |
Message-ID: | 570E3BA5.8060809@gmx.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 03/20/2016 06:40 PM, Yuri Niyazov wrote:
> [4:35pm] yuri_niyazov: "Again, use compatible initdb flags that match
> the old cluster" - this is when running initdb before running pg_upgrade
> [4:36pm] RhodiumToad: same encoding, locale, and checksum settings
> [4:36pm] yuri_niyazov: Can I recover those from the data directory? The
> previous initdb was ran 3 admins ago
> [4:37pm] RhodiumToad: psql -l against the old server and look at the
> encoding and locale for template0
> [4:37pm] RhodiumToad: checksums are almost certainly not enabled, but
> you can check that by running pg_controldata against the old data dir
> [4:38pm] yuri_niyazov: thank you!
> [4:38pm] RhodiumToad: (if the old server is too old for checksums, then
> don't enable them in the new initdb)
>
> I took RhodiumToad's comments and made them into a patch to pg_upgrade's
> documentation.
I think it's worth clarifying the documentation along the lines you
suggest, but I'm not sure about the details. A better way to get the
*cluster* locale is from pg_controldata. I don't know to what extent
pg_upgrade actually requires the encoding to match, since that is mostly
determined by the locale, and in the cases it's not, it might not matter.
Interesting to me would be a way, perhaps with an option in initdb, to
just say, initialize this cluster compatibly with that other cluster, so
you don't have to worry about these details.
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2016-04-13 12:36:47 | Re: Re: [COMMITTERS] pgsql: Avoid extra locks in GetSnapshotData if old_snapshot_threshold < |
Previous Message | Michael Paquier | 2016-04-13 12:21:29 | Re: Missing PG_INT32_MIN in numutils.c |