Re: How to restore from backup to 8.4.3 server using 9.0 dump/restore

From: "Andrus Moor" <eetasoft(at)online(dot)ee>
To: <adrian(dot)klaver(at)gmail(dot)com>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: How to restore from backup to 8.4.3 server using 9.0 dump/restore
Date: 2010-12-15 15:15:02
Message-ID: A64CA600C6FD4792AB441494A8C354C0@andrusnotebook
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Adrian,

thank you.

> I am not sure I follow. Are you taking a pg_dump of a 9.0 database using a
> 9.0
> version of pg_dump and trying to restore to a 8.4.3 database or are using
> the
> 9.0 pg_dump against the 8.4.3 server and then restoring back to it? In
> either
> case the problem you see above will probably be only the first.

I used only 9.0 dump and restore. I did the following:

1. Created backup copy from 8.4.3 using 9.0 pg_dump
2. Restored from this backup to 8.4.3 using 9.0 pg_restore

9.0 pg_restore fails since 8.4.3 server reports invalid sql command in
create
language plpgsql statement. previous pg_restores worked OK.
Is this 9.0 pg_restore bug ?

> Going backwards
> using pg_dump/pg_restore is not guaranteed to work. Your best hope if you
> must
> do that is to do the dump in plain text format and change the problems
> manually
> as you proceed.

Application executes 9.0 pg_dump/pg_restore
Application can connect to different servers starting and 8.1 and need to
able for backup/restore for every this server.
For single backup copy, dump and restore are executed for same server
version,

e.q backup created from site A using Postgres version x will used to
restore
only to this site for same postgres version x
Backup created from site B using Postgres version y will used to restore
only to
this site to same Postgres version y

How to support backup restore for all >=8.1 servers using single
pg_dump/pg_restore ?

Currently I looks like for 8.4 serves 9.0 backup/restore cannot used.

Andrus.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Yan Cheng CHEOK 2010-12-15 15:17:30 Fast Insert and Update (through COPY)
Previous Message Bryan Montgomery 2010-12-15 15:13:46 Searing array fields - or should I redesign?