Обсуждение: pg_dump version conflict

Поиск
Список
Период
Сортировка

pg_dump version conflict

От
Tom Haddon
Дата:
Hi Folks,

I'm trying to move from version 7.2.4 to version 7.1.2. May seem
counterintuitive, but trust me, there's a reason.

Anyway, the problem I'm having is that the pg_dump file from
pg_dump_7.2.4 doesn't seem to to work with 7.1.2 when I try to restore.
And when I try using pg_dump_7.1.2 to dump from the 7.2.4 database, I
get the following error message:

Database version: PostgreSQL 7.2.4 on i686-pc-linux-gnu, compiled by
GCC 2.96
Archiver(db) version: 7.1.2
Proceeding despite version mismatch.
getTables(): SELECT (for PRIMARY KEY) failed on table administrators.
 Explanation from backend: ERROR:  Attribute 'oid' not found


Is there any way round this? Or is there a better way to move from 7.2.4
to 7.1.2?

Thanks, Tom

--
______________________________
Tom Haddon
The Better Health Foundation
www.betterhealthfoundation.org
510.444.5096
______________________________


Re: pg_dump version conflict

От
Andrew Sullivan
Дата:
On Tue, Mar 25, 2003 at 01:54:41PM -0800, Tom Haddon wrote:
> Hi Folks,
>
> I'm trying to move from version 7.2.4 to version 7.1.2. May seem
> counterintuitive, but trust me, there's a reason.

It's going to be painful.  In general, there is no
backwards-migration path.  This is, in my view, rather a significant
weakness during upgrades; that said, I've never actually had an
iupgrade fail completely.

What you probably need to do is figure out how to edit the dumpfile
from 7.2.4 using sed, such that it can be made happy in 7.1.  I was
forced to do something similar one time.  It's fun like root canal,
but it's possible.

I am curious, though, what the reason for going backwards --
especially to 7.1.2 instead of 7.1.3 -- is.

A

--
----
Andrew Sullivan                         204-4141 Yonge Street
Liberty RMS                           Toronto, Ontario Canada
<andrew@libertyrms.info>                              M2P 2A8
                                         +1 416 646 3304 x110


Re: pg_dump version conflict

От
Tom Haddon
Дата:
Hmm... doesn't sound too promising. We are moving web hosting companies,
and our new web host has an older version (olm.net). If there really is
no other way then we may decide to go with someone else, but I'd like to
avoid that if I can.

Do you know how I'd find out how to alter the dump file to work for
7.1.2?

Thanks, Tom

On Tue, 2003-03-25 at 14:18, Andrew Sullivan wrote:
> On Tue, Mar 25, 2003 at 01:54:41PM -0800, Tom Haddon wrote:
> > Hi Folks,
> >
> > I'm trying to move from version 7.2.4 to version 7.1.2. May seem
> > counterintuitive, but trust me, there's a reason.
>
> It's going to be painful.  In general, there is no
> backwards-migration path.  This is, in my view, rather a significant
> weakness during upgrades; that said, I've never actually had an
> iupgrade fail completely.
>
> What you probably need to do is figure out how to edit the dumpfile
> from 7.2.4 using sed, such that it can be made happy in 7.1.  I was
> forced to do something similar one time.  It's fun like root canal,
> but it's possible.
>
> I am curious, though, what the reason for going backwards --
> especially to 7.1.2 instead of 7.1.3 -- is.
>
> A
>
> --
> ----
> Andrew Sullivan                         204-4141 Yonge Street
> Liberty RMS                           Toronto, Ontario Canada
> <andrew@libertyrms.info>                              M2P 2A8
>                                          +1 416 646 3304 x110
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
>     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
--
______________________________
Tom Haddon
The Better Health Foundation
www.betterhealthfoundation.org
510.444.5096
______________________________


Re: pg_dump version conflict

От
Robert Treat
Дата:
On Tue, 2003-03-25 at 17:24, Tom Haddon wrote:
> Hmm... doesn't sound too promising. We are moving web hosting companies,
> and our new web host has an older version (olm.net). If there really is
> no other way then we may decide to go with someone else, but I'd like to
> avoid that if I can.
>
> Do you know how I'd find out how to alter the dump file to work for
> 7.1.2?
>

I think you pretty much have to "brute force" it by taking the 7.2 dump
and loading into 7.1, seeing what errors it generates, then modifying
the dump to get past the errors, lather, rinse, repeat.

I'd strongly recommend finding another web host. There are enough
performance and security issues involved to make it worth your while to
try and find someone who is supporting 7.3.  I would tend to think that
anyone still running 7.1.x is either disinterested or not too attentive
to the machines and software under their watch, neither of which is a
quality you want to have in a hosting provider.

Robert Treat


Re: pg_dump version conflict

От
Vincent Janelle
Дата:
Either that or unwilling to bear the cost of support from just upgrading
a user's database and having to deal with incompatibilities.

On 25 Mar 2003 17:51:34 -0500
Robert Treat <xzilla@users.sourceforge.net> wrote:
>
> I'd strongly recommend finding another web host. There are enough
> performance and security issues involved to make it worth your while
> to try and find someone who is supporting 7.3.  I would tend to think
> that anyone still running 7.1.x is either disinterested or not too
> attentive to the machines and software under their watch, neither of
> which is a quality you want to have in a hosting provider.


Re: pg_dump version conflict

От
Andrew Sullivan
Дата:
On Tue, Mar 25, 2003 at 02:24:22PM -0800, Tom Haddon wrote:
> Do you know how I'd find out how to alter the dump file to work for
> 7.1.2?

I'm afraid what Robert Treat said: try loading, find the error, and
keep making changes til it works.

Could you convince them to let you install a private version of
Postgres, and use that?  Installing Postgres without root is a little
tricky, but not real hard.  The only thing you really need root for
is adding the init script.

I tend to agree with the other thing Robert said: that someone who
makes you stick with 7.1.2 is not providing the sort of support you
likely want.  If nothing else, the VACUUM change alone is worth
chucking 7.1.x overboard.  We saw a huge performance improvement when
we went from 7.1.3 to 7.2.2.  Part of that was just our freedom from
the old vacuum code, which caused us to have to neglect some tables
because of the cost of vacuuming them more often.

A

--
----
Andrew Sullivan                         204-4141 Yonge Street
Liberty RMS                           Toronto, Ontario Canada
<andrew@libertyrms.info>                              M2P 2A8
                                         +1 416 646 3304 x110


Re: pg_dump version conflict

От
Tom Haddon
Дата:
Hi Andrew,

Yeah, I'd tried the installing a private instance idea, and it seemed to
make the most sense, as it was on a Virtual Private Server.
Unfortunately, the gmake failed as it doesn't have "sort" installed. It
had taken me a while with tech support to get them to install GCC and
gmake, and I figured this was just going to take me too much time to get
through - if "sort" wasn't installed, god knows what else wasn't.

I'm currently investigating other web hosting companies.

Any recommendations. Lower end of pricing (>$30/month) appreciated?

Thanks, Tom

On Wed, 2003-03-26 at 12:17, Andrew Sullivan wrote:
> On Tue, Mar 25, 2003 at 02:24:22PM -0800, Tom Haddon wrote:
> > Do you know how I'd find out how to alter the dump file to work for
> > 7.1.2?
>
> I'm afraid what Robert Treat said: try loading, find the error, and
> keep making changes til it works.
>
> Could you convince them to let you install a private version of
> Postgres, and use that?  Installing Postgres without root is a little
> tricky, but not real hard.  The only thing you really need root for
> is adding the init script.
>
> I tend to agree with the other thing Robert said: that someone who
> makes you stick with 7.1.2 is not providing the sort of support you
> likely want.  If nothing else, the VACUUM change alone is worth
> chucking 7.1.x overboard.  We saw a huge performance improvement when
> we went from 7.1.3 to 7.2.2.  Part of that was just our freedom from
> the old vacuum code, which caused us to have to neglect some tables
> because of the cost of vacuuming them more often.
>
> A
>
> --
> ----
> Andrew Sullivan                         204-4141 Yonge Street
> Liberty RMS                           Toronto, Ontario Canada
> <andrew@libertyrms.info>                              M2P 2A8
>                                          +1 416 646 3304 x110
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
>     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
--
______________________________
Tom Haddon
The Better Health Foundation
www.betterhealthfoundation.org
510.444.5096
______________________________


Re: pg_dump version conflict

От
Andrew Sullivan
Дата:
On Wed, Mar 26, 2003 at 12:36:14PM -0800, Tom Haddon wrote:

> through - if "sort" wasn't installed, god knows what else wasn't.

I know what that is like.  Our production environment explicitly
forbids compilers (among other things), so we can't build the software
there.

We therefore build a binary tree (along with all the libraries needed
-- we have a private copy of readline, for instance!) on another box,
and then tar up the whole thing, including necessary libraries, and
put it there.  It's a bit of a hassle, but it works, and prevents me
from waiting 3 months while some drone decides whether sed or nawk
are security risks.  So something similar might work for you.  You
need an extra, compatible machine, however.  And some extra disk in
your hosted environment.

> Any recommendations. Lower end of pricing (>$30/month) appreciated?

I'm afriad not.  The techdocs.postgresql.org site has some
suggestions, though.

A

--
----
Andrew Sullivan                         204-4141 Yonge Street
Liberty RMS                           Toronto, Ontario Canada
<andrew@libertyrms.info>                              M2P 2A8
                                         +1 416 646 3304 x110


Re: pg_dump version conflict

От
Robert Treat
Дата:
Well 7.1 was released what, 2 years ago? In that amount of time the
hosting company never had to bring up another machine where it could
have offered a newer version of PostgreSQL?  Have they never upgraded
their OS either?

Robert Treat

On Tue, 2003-03-25 at 18:16, Vincent Janelle wrote:
> Either that or unwilling to bear the cost of support from just upgrading
> a user's database and having to deal with incompatibilities.
>
> On 25 Mar 2003 17:51:34 -0500
> Robert Treat <xzilla@users.sourceforge.net> wrote:
> >
> > I'd strongly recommend finding another web host. There are enough
> > performance and security issues involved to make it worth your while
> > to try and find someone who is supporting 7.3.  I would tend to think
> > that anyone still running 7.1.x is either disinterested or not too
> > attentive to the machines and software under their watch, neither of
> > which is a quality you want to have in a hosting provider.