Re: machine-readable pg_controldata? - Mailing list pgsql-hackers

From Joe Conway
Subject Re: machine-readable pg_controldata?
Date
Msg-id 4B959D7A.6010907@joeconway.com
Whole thread Raw
In response to Re: machine-readable pg_controldata?  (Greg Smith <greg@2ndquadrant.com>)
Responses Re: machine-readable pg_controldata?
List pgsql-hackers
On 03/05/2010 10:28 AM, Greg Smith wrote:
> Heikki Linnakangas wrote:
>> Then again, if you don't use the copy in shared memory but just open the
>> pg_control file and read it in the UDF, you could implement this as a
>> pgfoundry module that works with older versions too.
>
> This is the direction I'd prefer to see this go in a 9.0 context.  It's
> easy enough to build a fully functional version that lives works via the
> same proposed final UDF interface, just with the extra step of reading
> the file.  Get that working, and you just added a useful module
> supporting all the way back to 8.2 (I think--not sure if there's been
> any other changes that would break this) that people would love to have.

FWIW, here is a quick and dirty effort:
 http://www.joeconway.com/source_code/pg_controldata.tar.gz

It turns out some minor changes are needed for 8.4 or earlier as some
attributes have been added to ControlFileData. Once we get general
agreement I can do that too. I have not bothered to start a pgfoundry
project yet -- thoughts?

Joe


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Re: incorrect exit code from psql with single transaction + violation of deferred FK constraint
Next
From: Fujii Masao
Date:
Subject: Re: machine-readable pg_controldata?