Re: Can't upgrade a DB from 8.4 to 9.3 with pg_uprade: pg 9 not started

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Sebastien Douche <sdouche(at)gmail(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Can't upgrade a DB from 8.4 to 9.3 with pg_uprade: pg 9 not started
Date: 2014-02-17 18:25:56
Message-ID: 20140217182556.GB18934@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Mon, Feb 17, 2014 at 12:54:02PM -0500, Bruce Momjian wrote:
> > > Does that help? Did you use a different environment for the check and
> > > non-check phases?
> >
> > I found a fiable solution: remove the -w option on the pg_ctl' wrapper
> > (and added sleep 5 for waiting the launch) when pg_upgrade want to
> > start PG. Tested on several db w/o issues. This option is broken on PG
> > <9 (several workaround exist in the code of pg_upgrade for it).
>
> Oh, that's interesting. We used to have a loop in there for cases where
> you we couldn't use -w, like for non-default connection settings, but I
> thought -w still worked for defaults, even back to 8.4.
>
> It is possible we removed something that we should no one needed anymore
> but that 8.4 needs, but I am unclear what that would be.

I checked this and we use the pg_ctl version that matches the server we
are starting/stopping, so that kills the idea we removed something in
pg_ctl needed in older versions:

snprintf(cmd, sizeof(cmd),
"\"%s/pg_ctl\" -w -l \"%s\" -D \"%s\" -o \"-p %d%s%s %s%s\" start",
cluster->bindir, SERVER_LOG_FILE, cluster->pgconfig, cluster->port,
---------------

You saw the failure running pg_dumpall --globals on the old server.
Does pg_ctl -w work on the old/8.4 server, meaning can you run the
pg_ctl -w command that appears in the pg_upgrade logs, and then run a
pg_dumpall command right after?

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ Everyone has their own god. +

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Cliff Pratt 2014-02-17 23:21:50 Re: [ADMIN] could not create lock file postmaster.pid: No such file or directory, but file does exist
Previous Message Bruce Momjian 2014-02-17 17:54:02 Re: Can't upgrade a DB from 8.4 to 9.3 with pg_uprade: pg 9 not started