How to use pg_upgrade for beta versions

From: René Leonhardt <rene(dot)leonhardt(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: How to use pg_upgrade for beta versions
Date: 2014-07-26 14:56:14
Message-ID: 53D3C18E.6050509@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

It has been recommended to pg_upgrade from 9.4 beta 1 to 2:
http://www.postgresql.org/message-id/20e710fd3e4790ee1051aa1e107d3708@postgresql.org

How do I that on the Ubuntu 14.04.1 PPA?
http://www.postgresql.org/download/linux/ubuntu/

Upgrading directly is not possible:
$ sudo apt-get dist-upgrade
Preparing to unpack .../postgresql-9.4_9.4~beta2-1.pgdg14.04+1_amd64.deb ...
ERROR: The database format changed between beta 1 and 2. Please dump
your 9.4 clusters first and remove them before upgrading the package.
dpkg: error processing archive
/var/cache/apt/archives/postgresql-9.4_9.4~beta2-1.pgdg14.04+1_amd64.deb
(--unpack):
subprocess new pre-installation script returned error exit status 1
Errors were encountered while processing:
/var/cache/apt/archives/postgresql-9.4_9.4~beta2-1.pgdg14.04+1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Executing apt-get install -f afterwards shows the same error.

At least I am able to upgrade/install postgresql-contrib-9.4
(9.4~beta2-1.pgdg14.04+1), which gives me following tools:
$ ls -1 /usr/lib/postgresql/9.4/bin/
clusterdb
createdb
createlang
createuser
dropdb
droplang
dropuser
oid2name
pg_archivecleanup
pg_basebackup
pgbench
pg_dump
pg_dumpall
pg_isready
pg_receivexlog
pg_recvlogical
pg_restore
pg_standby
pg_test_fsync
pg_test_timing
psql
reindexdb
vacuumdb
vacuumlo

/etc/postgresql/9.4/main/postgresql.conf data_directory still points to
the Beta 1 cluster in /var/lib/postgresql/9.4/main

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Adrian Klaver 2014-07-26 18:38:16 Re: How to use pg_upgrade for beta versions
Previous Message byfei163@163.com 2014-07-26 06:35:58 Re: PG_TERMINATE_BACKEND not working.