Aide sur pg_upgrade : il ne lance pas le nouveau postmaster

From: Sebastien Douche <sdouche(at)gmail(dot)com>
To: "pgsql-fr-generale(at)postgresql(dot)org" <pgsql-fr-generale(at)postgresql(dot)org>
Subject: Aide sur pg_upgrade : il ne lance pas le nouveau postmaster
Date: 2014-02-13 18:36:26
Message-ID: CAAGHeXF2cpqpJ=9RtbSsjjOGN2iBf_HULtJWB3EG8-V+HdFOhg@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-fr-generale

Hello,
je dois être crétin mais je n'arrive pas à utiliser cet outil, et
comme je ne vois personne avec le même soucis que moi sur le Ternet...

J'ai une 8.4 sur une Debian Lenny, installée avec les paquets Debian,
et une 9.3.2 installée à partir des sources dans un répertoire
particulier.

Le check se passe bien :
postgres(at)SPV:~$ /opt/nova/current/nova/parts/pg93/bin/pg_upgrade -b
/usr/lib/postgresql/8.4/bin -B /opt/nova/current/nova/parts/pg93/bin/
-d /srv/postgresql/8.4/main/ -D /srv/postgresql/9.3/main --check
Performing Consistency Checks
-----------------------------
Checking cluster versions ok
Checking database user is a superuser ok
Checking for prepared transactions ok
Checking for reg* system OID user data types ok
Checking for contrib/isn with bigint-passing mismatch ok
Checking for large objects ok
Checking for presence of required libraries ok
Checking database user is a superuser ok
Checking for prepared transactions ok

*Clusters are compatible*

Par contre, l'upgrade foire :
postgres(at)SPV:~$ /opt/nova/current/nova/parts/pg93/bin/pg_upgrade -b
/usr/lib/postgresql/8.4/bin -B /opt/nova/current/nova/parts/pg93/bin/
-d /srv/postgresql/8.4/main/ -D /srv/postgresql/9.3/main
Performing Consistency Checks
-----------------------------
Checking cluster versions ok
Checking database user is a superuser ok
Checking for prepared transactions ok
Checking for reg* system OID user data types ok
Checking for contrib/isn with bigint-passing mismatch ok
Checking for large objects ok
Creating dump of global objects
*failure*

Consult the last few lines of "pg_upgrade_utility.log" for
the probable cause of the failure.
Failure, exiting

Le fichier dit :

pg_upgrade run on Thu Feb 13 19:25:39 2014
-----------------------------------------------------------------

command: "/opt/nova/current/nova/parts/pg93/bin/pg_dumpall" --port
50432 --username "postgres" --schema-only --globals-only
--quote-all-identifiers --binary-upgrade -f
pg_upgrade_dump_globals.sql >> "pg_upgrade_utility.log" 2>&1
pg_dumpall: could not connect to database "template1": could not
connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.50432"?

Il ne trouve pas PG9. Ce qui est bien indiqué dans le fichier
pg_upgrade_server :

-----------------------------------------------------------------
pg_upgrade run on Thu Feb 13 19:25:39 2014
-----------------------------------------------------------------

command: "/usr/lib/postgresql/8.4/bin/pg_ctl" -w -l
"pg_upgrade_server.log" -D "/srv/postgresql/8.4/main/" -o "-p 50432 -c
autovacuum=off -c autovacuum_freeze_max_age=2000000000 -c
listen_addresses='' -c unix_socket_permissions=0700" start >>
"pg_upgrade_server.log" 2>&1
waiting for server to start.... done
server started

command: "/usr/lib/postgresql/8.4/bin/pg_ctl" -w -D
"/srv/postgresql/8.4/main/" -o "" -m fast stop >>
"pg_upgrade_server.log" 2>&1
waiting for server to shut down.... done
server stopped

PG8 est lancé, pas le 9. Chose "rigolote", si je lance PG9 à la main:

postgres(at)SPV:~$ /opt/nova/current/nova/parts/pg93/bin/pg_ctl -D
/srv/postgresql/9.3/main/ startserver starting
postgres(at)SPV:~$ LOG: database system was shut down at 2014-02-13 19:15:57 CET
LOG: database system is ready to accept connections
LOG: autovacuum launcher started

Ben il essaye de le lancer cette fois ci :

-----------------------------------------------------------------
pg_upgrade run on Thu Feb 13 19:28:26 2014
-----------------------------------------------------------------

command: "/opt/nova/current/nova/parts/pg93/bin/pg_ctl" -w -l
"pg_upgrade_server.log" -D "/srv/postgresql/9.3/main" -o "-p 50432 -c
autovacuum=off -c autovacuum_freeze_max_age=2000000000 -c
synchronous_commit=off -c fsync=off -c full_page_writes=off -c
listen_addresses='' -c unix_socket_permissions=0700" start >>
"pg_upgrade_server.log" 2>&1
pg_ctl: another server might be running; trying to start server anyway
waiting for server to start....FATAL: lock file "postmaster.pid" already exists
HINT: Is another postmaster (PID 17079) running in data directory
"/srv/postgresql/9.3/main"?
....
pg_ctl: this data directory appears to be running a pre-existing postmaster
stopped waiting
pg_ctl: could not start server
Examine the log output.

Ma question est donc : Ou je me goure ? Parce que pour moi, cela se
résume à faire un initdb et arrêter les postmaster. Je ne vois pas ce
que je rate.

--
Sebastien Douche <sdouche(at)gmail(dot)com>
Twitter: @sdouche / G+: +sdouche

--
Envoi via la liste pgsql-fr-generale (pgsql-fr-generale(at)postgresql(dot)org)

Responses

Browse pgsql-fr-generale by date

  From Date Subject
Next Message Pierre BOIZOT 2014-02-13 20:13:50 Re: Relation shared_buffers - Checkpoint
Previous Message pierre crumeyrolle 2014-02-13 16:30:53 Re: ORA2PG