backend corruption

From: "George Johnson" <gjohnson(at)jdsc(dot)com>
To: <pgsql-general(at)postgresql(dot)org>
Subject: backend corruption
Date: 2001-01-06 23:14:47
Message-ID: NEBBJGKMGLGMDGBMOHJNGEKNCAAA.gjohnson@jdsc.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello Everybody,

I've been whirling along with my new postgresql database (converted from
mysql before Christmas) and have been very pleased. Until a few days ago .
I was sittin there minding my own business WHEN ... (dot dot dot)

I was goofing around attempting to install new UDF's and in the process,
didn't notice that the backend had died. I'm not exactly sure when it died,
and since I had been sending output etc to /dev/null
(postmaster -i -o -F -S), not sure why it died, either. I was/am using the
snapshot as my working environment. Anyway, I started reading the list
archives and found lots of mentions of bad backend situations. Apparently
my pg_control was corrupted (?), there were no databases listed in my
pg_databases and some index tree was corrupted. (There was a thread a bit
ago about lack of documentation about certain postgresql features -- how
about *anything* regarding system tables ...)

So, somewhat blindly, I did a:

rm pg_control
initdb

Apparently, one other time someone had done this, then later it was
suggested s/he should attempt to re-construct pg_shadow and pg_databases.
But then, someone said, no way, can't do that, cause you can't restore a
database from those unnamed directories/files (which I *thought* were the
databases), you had to have the x_logs intact too.

So basically, I've wiped all my databases, it looks like, and no, there is
no directory/structure which atomically can be called "your database", other
than the ENTIRE data/base directory.

I have to just say this aspect of the mysql --> postgresql learning curve is
the most difficult and painful to grasp. pg_dump is *not* an optional thing
like mysqldump is (for mysql) ... you can't recover/backup a database just
by what's found in those numbered subdirectories.

If I've left a stone unturned, please let me know.
Thanks,
George Johnson

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Brett W. McCoy 2001-01-06 23:32:25 Re: backend corruption
Previous Message Brett W. McCoy 2001-01-06 21:45:26 Re: Loading optimization