pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Error Migrating From 7.4 to 8.2.5
3+ messages / 2 participants
[nested] [flat]

* Error Migrating From 7.4 to 8.2.5
@ 2007-11-05 11:40  eromain@patriot.net
  0 siblings, 1 reply; 3+ messages in thread

From: eromain@patriot.net @ 2007-11-05 11:40 UTC (permalink / raw)
  To: pgsql-admin

I am running PGSQL 7.4 on a Solaris 9 system. I am trying to upgrade to
8.2.5. Both 7.4 and 8.2.5 are on the same server. When I try to use 8.2.5
pg_dumpall to dump the 7.4 databse I receive the following error:
pg_dumpall: query failed: ERROR:  xlog flush request 58/A0AFB0C0 is not
satisfied --- flushed only to 5/B2004628
CONTEXT:  writing block 15 of relation 21182403/16408
pg_dumpall: query was: SELECT usename as rolname, usesuper as rolsuper,
true as rolinherit, usesuper as rolcreaterole, usecreatedb as rolcreatedb,
usecatupd as rolcatupdate, true as rolcanlogin, -1 as rolconnlimit, passwd
as rolpassword, valuntil as rolvaliduntil, null as rolcomment FROM
pg_shadow UNION ALL SELECT groname as rolname, false as rolsuper, true as
rolinherit, false as rolcreaterole, false as rolcreatedb, false as
rolcatupdate, false as rolcanlogin, -1 as rolconnlimit, null::text as
rolpassword, null::abstime as rolvaliduntil, null as rolcomment FROM
pg_group WHERE NOT EXISTS (SELECT 1 FROM pg_shadow  WHERE usename =
groname) ORDER BY 1

I shut down the 7.4 database and ran pg_resetxlog. This is just a test so
I am not worried about losing data. Restarted the database and tried
pg_dumpall again. I still received the same error but on a different
block. How do I fix this problem? Thank you.




^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Error Migrating From 7.4 to 8.2.5
@ 2007-11-05 13:26  Tom Lane <tgl@sss.pgh.pa.us>
  parent: eromain@patriot.net
  0 siblings, 1 reply; 3+ messages in thread

From: Tom Lane @ 2007-11-05 13:26 UTC (permalink / raw)
  To: eromain@patriot.net; +Cc: pgsql-admin

eromain@patriot.net writes:
> I am running PGSQL 7.4 on a Solaris 9 system.

7.4.what exactly?

> I am trying to upgrade to
> 8.2.5. Both 7.4 and 8.2.5 are on the same server. When I try to use 8.2.5
> pg_dumpall to dump the 7.4 databse I receive the following error:
> pg_dumpall: query failed: ERROR:  xlog flush request 58/A0AFB0C0 is not
> satisfied --- flushed only to 5/B2004628
> CONTEXT:  writing block 15 of relation 21182403/16408

Hmmm ... in 7.4 16408 is pg_statistic, which fortunately for you is all
easily-regenerated data.  I'd try "DELETE FROM pg_statistic".
If that doesn't complain, the normal process would be to VACUUM pg_statistic 
and then re-ANALYZE the database, but since you're just trying to dump
data you might be able to skip that bit.

> I shut down the 7.4 database and ran pg_resetxlog. This is just a test so
> I am not worried about losing data.

Good, because that wasn't a very bright move --- I can't imagine that
the shutdown checkpoint would have worked, and pg_resetxlog after an
unclean shutdown is a recipe for losing data.

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: Error Migrating From 7.4 to 8.2.5
@ 2007-11-05 15:42  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 3+ messages in thread

From: Tom Lane @ 2007-11-05 15:42 UTC (permalink / raw)
  To: eromain@patriot.net; +Cc: pgsql-admin

eromain@patriot.net writes:
>> Hmmm ... in 7.4 16408 is pg_statistic, which fortunately for you is all
>> easily-regenerated data.  I'd try "DELETE FROM pg_statistic".

> Deleting from pg_statistic produced error: xlog flush request 58/A0AFB340
> is not satisfied --- flushed only to 5/B2004628
> CONTEXT:  writing block 3 of relation 21182403/16408

Ugh ... it's troubling that you have this on several different pages;
that makes it more probable that the corruption extends beyond
pg_statistic.  Anyway, the next thing to try is manually truncating the
file to zero length (while the postmaster is stopped).  Check the
database OID, then it should be $PGDATA/base/DBOID/16408.

> I am running just 7.4. Thanks!!

Yikes.  The current release in that branch is 7.4.18, and practically
every one of those 18 updates fixed significant bugs.

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2007-11-05 15:42 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2007-11-05 11:40 Error Migrating From 7.4 to 8.2.5 eromain@patriot.net
2007-11-05 13:26 ` Tom Lane <tgl@sss.pgh.pa.us>
2007-11-05 15:42   ` Tom Lane <tgl@sss.pgh.pa.us>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox