Received: from localhost (unknown [200.46.204.183]) by developer.postgresql.org (Postfix) with ESMTP id DBAEC2E0083 for ; Mon, 21 Apr 2008 08:51:32 -0300 (ADT) Received: from developer.postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 31885-07 for ; Mon, 21 Apr 2008 08:51:23 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from out1.smtp.messagingengine.com (out1.smtp.messagingengine.com [66.111.4.25]) by developer.postgresql.org (Postfix) with ESMTP id C0CCB2E007C for ; Mon, 21 Apr 2008 08:51:22 -0300 (ADT) Received: from compute1.internal (compute1.internal [10.202.2.41]) by out1.messagingengine.com (Postfix) with ESMTP id D8FD7100CF0 for ; Mon, 21 Apr 2008 07:51:21 -0400 (EDT) Received: from web6.messagingengine.com ([10.202.2.215]) by compute1.internal (MEProxy); Mon, 21 Apr 2008 07:51:21 -0400 Received: by web6.messagingengine.com (Postfix, from userid 99) id BF2DC1C5D7; Mon, 21 Apr 2008 07:51:21 -0400 (EDT) Message-Id: <1208778681.11353.1248996817@webmail.messagingengine.com> X-Sasl-Enc: BY+Bkus2elCAKX/wTdbPGescJ9eg+i/3ubXyDMafZUE4 1208778681 From: "Darren Reed" To: pgsql-admin@postgresql.org Content-Disposition: inline Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="ISO-8859-1" MIME-Version: 1.0 X-Mailer: MessagingEngine.com Webmail Interface Subject: Some additions to pg_filedump... Date: Mon, 21 Apr 2008 13:51:21 +0200 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200804/210 X-Sequence-Number: 28974 I did a bit of hacking on pg_filedump to make it slightly more useful...but it wasn't clear where or to whom the patches should be sent, so I'm sending an email to pgsql-admins 'cause they're the kind of folks that probably care about them... The changes I added are two command line options: -F to filter out which items get dumped. presently only works on the infomask field. -T to dump out each item according to either int,char,varchar,bool types (yes, I know, that's not all of the postgres types.) -q to supress lots of additional output (quiet) Now, combined they allow data to be recovered from a situation where the index is fubar'd but you've still got good data and you don't want to recover from backup...that said, there is great danger because pg_filedump doesn't know which item from the dataset is the most recent/alive one. If there's further interest, I can add more types but the warning above holds. pg_filedump shouldn't be used for what the above makes easy but I can't see why that shouldn't be a decision we (and not the db) gets to make... Cheers, Darren http://coombs.anu.edu.au/~avalon/pg_fd_FT.patch.gz