Re: Help me recovering data - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Help me recovering data
Date
Msg-id 535.1108410034@sss.pgh.pa.us
Whole thread Raw
In response to Re: Help me recovering data  (Christopher Kings-Lynne <chriskl@familyhealth.com.au>)
Responses Re: Help me recovering data
List pgsql-hackers
Christopher Kings-Lynne <chriskl@familyhealth.com.au> writes:
> This might seem like a stupid question, but since this is a massive data 
> loss potential in PostgreSQL, what's so hard about having the 
> checkpointer or something check the transaction counter when it runs and 
>   either issue a db-wide vacuum if it's about to wrap, or simply 
> disallow any new transactions?

The checkpointer is entirely incapable of either detecting the problem
(it doesn't have enough infrastructure to examine pg_database in a
reasonable way) or preventing backends from doing anything if it did
know there was a problem.

> I think people'd rather their db just stopped accepting new transactions 
> rather than just losing data...

Not being able to issue new transactions *is* data loss --- how are you
going to get the system out of that state?

autovacuum is the correct long-term solution to this, not some kind of
automatic hara-kiri.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Schema name of function
Next
From: pgsql@mohawksoft.com
Date:
Subject: Re: enforcing a plan (in brief)