Re: pg_upgrade & tablespaces - Mailing list pgsql-general

From Adrian Klaver
Subject Re: pg_upgrade & tablespaces
Date
Msg-id 52C3397C.7060003@gmail.com
Whole thread Raw
In response to Re: pg_upgrade & tablespaces  (Joseph Kregloh <jkregloh@sproutloud.com>)
Responses Re: pg_upgrade & tablespaces
List pgsql-general
On 12/31/2013 01:31 PM, Joseph Kregloh wrote:
>
>         ERROR:  relation "sys_errors" does not exist
>         LINE 1: SELECT * FROM sys_errors ORDER BY created_ts DESC LIMIT 100;
>                                 ^
>         ********** Error **********
>
>         ERROR: relation "sys_errors" does not exist
>         SQL state: 42P01
>         Character: 15
>
>
>     sys_errors is a table in the tablespace correct?
>
>
> Yes it is.

So you have not upgraded the tablespaces. What is important to remember
is Postgres uses numbers to keep track of relations. Part of the upgrade
process involves changing the numbers that point at relations. By
manually dropping a 9.0 tablespace into a 9.3 data directory you have
broken that system. You need to let  pg_upgrade do the translation. See
my previous message below for a possible solution:

http://www.postgresql.org/message-id/52BDE16D.4090601@gmail.com

>
>
>         The second test, using the exact same pg_upgrade line. But this
>         time I
>         updated the location of the tablespaces to outside the /data
>         directory.
>         I updated pg_tablespace and re-created all symlinks. Now the data
>         directory doesn't contain the tablespaces. Again pg_upgrade
>         completes
>         successfully and again I get the same error about the relation.
>
>         Any thoughts?
>
>
>
>     --
>     Adrian Klaver
>     adrian.klaver@gmail.com <mailto:adrian.klaver@gmail.com>
>
>


--
Adrian Klaver
adrian.klaver@gmail.com


pgsql-general by date:

Previous
From: Joseph Kregloh
Date:
Subject: Re: pg_upgrade & tablespaces
Next
From: Joseph Kregloh
Date:
Subject: Re: pg_upgrade & tablespaces