Re: pg_upgrade: "pg_ctl failed to start the new server"

From: "Evan D(dot) Hoffman" <evandhoffman(at)gmail(dot)com>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Postgresql Mailing List <pgsql-general(at)postgresql(dot)org>
Subject: Re: pg_upgrade: "pg_ctl failed to start the new server"
Date: 2012-06-14 12:03:49
Message-ID: CABRB-LvXjW8y6sMNtXRqJhuGODqcaBzjCSdpSKy8rAuDZmxruA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Woops. The file that had to be renamed was
/etc/ld.so.conf.d/postgresql-9.0-libs.conf =>
postgresql-9.old-libs.conf . Prior to rename, ldconfig output was:

# ldconfig -p | grep pq
libpqwalreceiver.so (libc6) => /usr/pgsql-9.0/lib/libpqwalreceiver.so
libpqwalreceiver.so (libc6) => /usr/pgsql-9.1/lib/libpqwalreceiver.so
libpq.so.5 (libc6) => /usr/pgsql-9.0/lib/libpq.so.5
libpq.so.5 (libc6) => /usr/pgsql-9.1/lib/libpq.so.5
libpq.so (libc6) => /usr/pgsql-9.0/lib/libpq.so
libpq.so (libc6) => /usr/pgsql-9.1/lib/libpq.so

After the rename:

# cd /etc/ld.so.conf.d
# mv postgresql-9.0-libs.conf postgresql-9.old-libs.conf
# ldconfig
# ldconfig -p | grep pq
libpqwalreceiver.so (libc6) => /usr/pgsql-9.1/lib/libpqwalreceiver.so
libpqwalreceiver.so (libc6) => /usr/pgsql-9.0/lib/libpqwalreceiver.so
libpq.so.5 (libc6) => /usr/pgsql-9.1/lib/libpq.so.5
libpq.so.5 (libc6) => /usr/pgsql-9.0/lib/libpq.so.5
libpq.so (libc6) => /usr/pgsql-9.1/lib/libpq.so
libpq.so (libc6) => /usr/pgsql-9.0/lib/libpq.so

So it appears the problem was inability to connect, although
pg_upgrade reported that it couldn't start the server (I assume
ability to connect is how it determines whether or not the server was
started).

On Wed, Jun 13, 2012 at 10:49 PM, Bruce Momjian <bruce(at)momjian(dot)us> wrote:
> On Wed, Jun 13, 2012 at 10:41:37PM -0400, Evan D. Hoffman wrote:
>> Actually I found the solution right after I sent that email (of
>> course):
>>
>> https://wiki-bsse.ethz.ch/download/attachments/55283107/PostgreSQL_9_M
>> aintenance_Backup_and_Recovery_final.docx
>>
>> Has to do with the order in which shared libs are loaded when both 9.0
>> and 9.1 are installed.  Renaming the config file as described in that
>> doc resolved it.
>
> I didn't find out which file you renamed.  Why would the server show as
> started while pg_ctl -w returned an error?  I am guessing that you could
> not connect somehow.
>
> --
>  Bruce Momjian  <bruce(at)momjian(dot)us>        http://momjian.us
>  EnterpriseDB                             http://enterprisedb.com
>
>  + It's impossible for everything to be true. +

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Egidijus 2012-06-14 12:31:55 about seperate users in PostgreSQL
Previous Message Stefan Schwarzer 2012-06-14 11:47:30 Re: Problem installing extensions on Lion