Re: Upgrade/Installation problem: Version 7.4.9 to version

From: Jeff Frost <jeff(at)frostconsultingllc(dot)com>
To: Andrew Edson <cheighlund(at)yahoo(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Upgrade/Installation problem: Version 7.4.9 to version
Date: 2007-01-17 21:13:12
Message-ID: Pine.LNX.4.64.0701171304300.31602@discord.home.frostconsultingllc.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Please reply-all when replying so everyone can help.

What I mean is that I have a physical server db1 which is old and meant to be
replaced by new shiny physical server db2.

Let me ask a different question, because it seems perhaps I didn't understand
your original email.

Are you just trying to upgrade from postgresql 7.4.9 to 8.1.3 (I'd suggest
8.1.6 myself) on the same physical machine?

If so, then you need to use an intermediate file like this:

(starting from when postgresql-7.4.9 is running)
/usr/local/src/postgresql-8.1.6/src/bin/pg_dump/pg_dumpall | gzip > dumpall.gz
stop postgresql 7.4.9 server
rename the 7.4.9 data directory
install postgresql-8.1.6
initdb -E UTF8 -D /var/lib/pgsql/data
(or wherever your data directory is to reside)
start postgresql 8.1.6
zcat dumpall.gz | psql postgres

On Wed, 17 Jan 2007, Andrew Edson wrote:

> I'm not understanding part of what you wrote. Unless you mean the
> upgrading, I'm not certain what you mean by 'replace' in your example.
> Should I be trying to have both copies of Postgres running at once or
> something like that? And if so, how would I do that?
>
> Jeff Frost <jeff(at)frostconsultingllc(dot)com> wrote: You have to dump the original 7.4.9 version of the database and restore that
> into the 8.1.3 database server.
>
> An example:
>
> I have a server db1 which is running pg 7.4.9
> I have a server db2 which is to replace db1 running pg 8.1.3
>
> I would likely just do something like this from db2 (assuming no clients are
> writing to db1 while this is happening):
>
> pg_dumpall -h db1 | psql -h db2
>
>
> ---------------------------------
> TV dinner still cooling?
> Check out "Tonight's Picks" on Yahoo! TV.

--
Jeff Frost, Owner <jeff(at)frostconsultingllc(dot)com>
Frost Consulting, LLC http://www.frostconsultingllc.com/
Phone: 650-780-7908 FAX: 650-649-1954

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Jeff Frost 2007-01-17 21:18:06 Re: Upgrade/Installation problem: Version 7.4.9 to version
Previous Message Ray Stell 2007-01-17 21:12:25 Re: Upgrade/Installation problem: Version 7.4.9 to version