From: | Matt Landry <lelnet(dot)matt(at)gmail(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: pg_upgrade failing from 9.3 to 9.4 because "template0" already exists |
Date: | 2015-03-06 19:22:27 |
Message-ID: | 54F9FE73.5030800@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On 03/06/2015 12:37 PM, Adrian Klaver wrote:
> Agreed, I am just trying to figure out how you get:
>
> CREATE DATABASE "template0" WITH TEMPLATE = template0 ..
>
> Seems to be a snake eating its tail:)
Yes. It does. And it's pretty obvious why having this would be a
problem...not quite so obvious how to not have it.
For the record, I inherited this DB configuration, but I can say with
certainty that we have _one_ actual database with data in it, and it's
not "template0". If it turns out that, in order to do what I need to do,
we need to either drop (or rename, or whatever) template0 or somehow
manually exclude the attempt to upgrade template0, and that for some
reason we have local modifications to that template that will then have
to be re-done, then that's a totally acceptable solution, from my
perspective, as long as we (that is, me and all the people who read the
pg_upgrade documentation in the future) know how to do that.
But figuring out how it managed to get into this condition in the first
place, and how pg_upgrade can be made to programmatically cope with
that, is probably more important for all the users who aren't me. :)
From | Date | Subject | |
---|---|---|---|
Next Message | Adrian Klaver | 2015-03-06 19:31:16 | Re: pg_upgrade failing from 9.3 to 9.4 because "template0" already exists |
Previous Message | Adrian Klaver | 2015-03-06 18:37:39 | Re: pg_upgrade failing from 9.3 to 9.4 because "template0" already exists |