From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | James(王旭) <wangxu(at)gu360(dot)com> |
Cc: | pgsql-general <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: What to do with tablespaces when upgrading to pg13 from pg1X? |
Date: | 2021-01-12 02:45:42 |
Message-ID: | 20210112024541.GA4329@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Tue, Jan 12, 2021 at 10:28:52AM +0800, James(王旭) wrote:
> Hello,
> I was planning to upgrade from 12 to 13 using this command:
>
> /usr/pgsql-13/bin/pg_upgrade -b /usr/pgsql-12/bin/ -B /usr/pgsql-13/bin/ -d
> /data/pg/ -D /pg/pgdata_13/ --jobs=10
>
>
> And I got this output:
>
> Checking for presence of required libraries ok
> Checking database user is the install user ok
> Checking for prepared transactions ok
> Checking for new cluster tablespace directories
> new cluster tablespace directory already exists: "/data/tsdb/metas/
> PG_13_202007201"
> Failure, exiting
>
> I think it's because /data/tsdb was my tablespace dir which was out of the old
> main data directory(/data/pg/).
>
> So what should I do with old tablespaces when upgrading ?
There should be a subdirectory under your tablespace directory for every
major version, e.g., PG_13_202007201. I have no idea why your _new_
version already has a directory there. Do you have a second cluster on
the machine that is using that tablespace directory for PG 13?
--
Bruce Momjian <bruce(at)momjian(dot)us> https://momjian.us
EnterpriseDB https://enterprisedb.com
The usefulness of a cup is in its emptiness, Bruce Lee
From | Date | Subject | |
---|---|---|---|
Next Message | James (王旭) | 2021-01-12 02:50:16 | Re: What to do with tablespaces when upgrading to pg13 from pg1X? |
Previous Message | James (王旭) | 2021-01-12 02:28:52 | What to do with tablespaces when upgrading to pg13 from pg1X? |