Re: Upgrade from 9.5.4 to 9.6.1

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Rich Shepard <rshepard(at)appl-ecosys(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: Upgrade from 9.5.4 to 9.6.1
Date: 2016-11-16 00:55:02
Message-ID: bd6ee54b-ab53-f7ae-1621-6bca77bb4d16@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 11/15/2016 02:37 PM, Rich Shepard wrote:
> All my previous version upgrades were performed by running pg_dumpall in
> the older version followed by running 'pgsql -f ...' to install the dumped
> .sql file, usually because the upgrade jumped several versions. Now I'd
> like
> to try the available postgres commands.
>
> The older version is installed in /var/lib/pgsql/9.5/data and I just
> initiated the new version in /var/lib/pgsql/9.6/data. The earlier
> version is
> currently running.
>
> Is pg_upgrade the recommended way to upgrade from one minor version to
> the
> next? The 9.5 manual recommends this approach for _major_ upgrades (e.g.,
> 8.4.7 to 9.6.1), but not for _minor_ upgrades (e.g., 9.0.1 to 9.0.4).
> That's
> a first digit upgrade and a third digit upgrade. Since 9.5.4 to 9.6.1 is a
> second digit upgrade I suppose it's semi-major, but in which upgrade camp
> does it belong?
>
> The command is:
>
> pg_upgrade -b oldbindir -B newbindir -d olddatadir -D newdatadir
>
> and I don't know where to find -b and -B. On my Slackware-14.1 server I
> have
> /usr/bin/postgres and assume it is for the 9.5 release since that's running
> and the 9.6 release is initiated but not invoked. The data directories are
> easy but where do I look for the two bindirs?

Assuming the bindirs are in your $PATH:

aklaver(at)panda:~> whereis -f pg_ctl
pg_ctl: /usr/local/pgsql/bin/pg_ctl /usr/local/pgsql94/bin/pg_ctl

Even if only one is the $PATH:

aklaver(at)panda:~> whereis -f pg_ctl
pg_ctl: /usr/local/pgsql/bin/pg_ctl

you can usually figure out where the other is.

>
> TIA,
>
> Rich
>
>
>

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Rich Shepard 2016-11-16 01:00:21 Re: Upgrade from 9.5.4 to 9.6.1
Previous Message John R Pierce 2016-11-16 00:25:45 Re: Upgrade from 9.5.4 to 9.6.1