Re: oids rollover? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: oids rollover?
Date
Msg-id 3059.1024965646@sss.pgh.pa.us
Whole thread Raw
In response to oids rollover?  (Daniel Kalchev <daniel@digsys.bg>)
List pgsql-hackers
Daniel Kalchev <daniel@digsys.bg> writes:
> I have a problem with an 7.1.3 database that has probably overflowed
> the oid counter. The startup halts with these messages

> DEBUG:  database system was interrupted at 2002-06-24 21:19:43 EEST
> DEBUG:  CheckPoint record at (156, 1692817164)
> DEBUG:  Redo record at (156, 1692775580); Undo record at (0, 0);
> Shutdown FALSE
> DEBUG:  NextTransactionId: 859255800; NextOid: 7098
> FATAL 2:  Invalid NextTransactionId/NextOid
> postmaster: Startup proc 4752 exited with status 512 - abort

Looks that way.  This is fixed in 7.2, so you might want to think about
an update sometime soon.

> Can something be sone to recover the database?

You could modify contrib/pg_resetxlog to force a value at least 16384 into
the OID counter.  Since the DB was evidently not shut down cleanly, I'd
counsel cutting out the xlog-reset function entirely; just make it read
the pg_control file, set a valid nextOid, update the CRC, and rewrite
pg_control.
        regards, tom lane




pgsql-hackers by date:

Previous
From: "J. R. Nield"
Date:
Subject: Re: Index Scans become Seq Scans after VACUUM ANALYSE
Next
From: Rod Taylor
Date:
Subject: Re: Nonrecursive ALTER TABLE ADD/RENAME COLUMN is wrong