Re: Diagnostic functions - Mailing list pgsql-patches

From Heikki Linnakangas
Subject Re: Diagnostic functions
Date
Msg-id 463F9ACB.4060502@enterprisedb.com
Whole thread Raw
In response to Re: Diagnostic functions  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: Diagnostic functions
List pgsql-patches
Peter Eisentraut wrote:
> Am Montag, 7. Mai 2007 11:49 schrieb Heikki Linnakangas:
>> It's handy to be able to inspect pages from within a live database.
>
> How reliable is it to inspect pages from within a database if you presumably
> suspect that database to be broken?

As long as the page header is valid, the functions should be able to
deal with it (as in not crashing).

I found them extremely useful when I was developing the MVCC-safe
CLUSTER patch. The index functions in pgstattuple were very useful when
I worked on clustered indexes. In fact I reinvented the wheel and wrote
a function of my own that did essentially the same thing as
bt_page_items, before Bruce pointed out that such a thing already exists.

>> We already played the name game on hackers. My original suggestion was
>> "pgforensics". "pgdiagfuncs" and "pginspect" were also suggested, among
>> others. I'm still open to suggestions, though. Have any?
>
> Something involving "page" would at least explain what you can diagnose.

Well, how about "pageinspect" then?

--
   Heikki Linnakangas
   EnterpriseDB   http://www.enterprisedb.com

pgsql-patches by date:

Previous
From: Tomas Doran
Date:
Subject: Implemented current_query
Next
From: "William Lawrance"
Date:
Subject: ECPG patch to use prepare for improved performance