pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Searching for a supposedly resolved bug report
2+ messages / 2 participants
[nested] [flat]

* Searching for a supposedly resolved bug report
@ 2005-09-21 06:47  Scott Eade <seade@backstagetech.com.au>
  0 siblings, 1 reply; 2+ messages in thread

From: Scott Eade @ 2005-09-21 06:47 UTC (permalink / raw)
  To: pgsql-admin

Environment: PostgreSQL 7.3.10-RH, RHEL3

As a result of a failed pg_restore (why it failed will be the subject of
another post) I ended up with a corrupted database (since dropped).

Somehow this resulted in postmaster crashing thus:

    PANIC: open of /var/lib/pgsql/data/pg_clog/0058 failed: No such file
or directory

Sure enough this file does not exist, the file in the pg_clog dir is
0060 (180224 bytes)

I mentioned this on the postgres irc channel, I have included the advice
provided by neilc below:

I am wondering if anyone can point me to the supposedly fixed bug that
would have caused this (is it just me or is it difficult to find
specific bugs using the mailing list - is there an issue tracker
somewhere?)  It would be nice to know how to avoid this in the future.

I am also interested in comments on the suggested solution.  I won't be
able to upgrade to a newer release for a couple of weeks, and then it
will only be to 7.4.x.  Is the suggested solution going to allow me to
continue using the databases (i.e. moving forward past the ability to
run a dump).

Thanks in advance for any comments.

Scott


=== Edited irc transcript below ===

neilc> hmm, i thought the fix for this was backported to 7.3.10
> but perhaps not in any case, this is a fairly serious bug
> that has been fixed in recent PG releases so i would
> recommend upgrading (e.g. to 8.0.3) once you've fixed the
> problem
> to fix the problem (i.e.allow pg_dump so you can upgrade),
> recreate the clog files
> they should be all-zeroes
> so use dd if=/dev/zero of=/the/file/in/clog
> the length should be a multiple of 8192
> basically, create a zero-length file
> PG will then complain it can't find any data at a particular offset
> then extend the file (with all-zeroes) to the offset PG complains
> about

Worryingly, someone else commented
> i'm thinking it could be prefaced with WARNING! YOU ARE ABOUT TO
DESTROY DATA! THIS IS THE LAST RESORT!

seade> I assume I need to drop postmaster before I do the
seade> dd if=/dev/zero of=/the/file/in/clog?
seade> what about the filename 0060 will this be tidied up
seade> too on restart?
neilc> seade: yeah, stop the postmaster first
neilc> seade: the filename is fine





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

* Re: Searching for a supposedly resolved bug report
@ 2005-09-21 14:50  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Scott Eade <seade@backstagetech.com.au>
  0 siblings, 0 replies; 2+ messages in thread

From: Tom Lane @ 2005-09-21 14:50 UTC (permalink / raw)
  To: Scott Eade <seade@backstagetech.com.au>; +Cc: pgsql-admin

Scott Eade <seade@backstagetech.com.au> writes:
> Environment: PostgreSQL 7.3.10-RH, RHEL3
>     PANIC: open of /var/lib/pgsql/data/pg_clog/0058 failed: No such file
> or directory

> I am wondering if anyone can point me to the supposedly fixed bug that
> would have caused this (is it just me or is it difficult to find
> specific bugs using the mailing list - is there an issue tracker
> somewhere?)  It would be nice to know how to avoid this in the future.

I suppose Neil is thinking of this:

http://archives.postgresql.org/pgsql-hackers/2004-10/msg00464.php

which is in fact fixed as of 7.3.8 --- but if you'd updated a pre-7.3.8
installation to 7.3.10 then damage from a previous triggering of the bug
could possibly still be lurking.

Or you could have been bit by something else that happens to have a
similar-looking symptom.  There's not enough info here to say.

			regards, tom lane



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


end of thread, other threads:[~2005-09-21 14:50 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2005-09-21 06:47 Searching for a supposedly resolved bug report Scott Eade <seade@backstagetech.com.au>
2005-09-21 14:50 ` 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