X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 5B374D1B4E9 for ; Sun, 2 Nov 2003 18:46:11 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 91017-01 for ; Sun, 2 Nov 2003 14:45:41 -0400 (AST) Received: from pasta.sw.starentnetworks.com (pasta.sw.starentnetworks.com [12.33.234.10]) by svr1.postgresql.org (Postfix) with ESMTP id CE349D1B58D for ; Sun, 2 Nov 2003 14:45:39 -0400 (AST) Received: by pasta.sw.starentnetworks.com (Postfix, from userid 1008) id B004D14A183; Sun, 2 Nov 2003 13:45:39 -0500 (EST) Date: Sun, 2 Nov 2003 13:45:39 -0500 From: Brian Ristuccia To: Tom Lane Cc: pgsql-admin@postgresql.org Subject: Re: dumping tables from badly damaged db Message-ID: <20031102184538.GL24232@sw.starentnetworks.com> References: <20031031161943.GB24232@sw.starentnetworks.com> <6231.1067627157@sss.pgh.pa.us> <20031031191546.GC24232@sw.starentnetworks.com> <16557.1067629557@sss.pgh.pa.us> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <16557.1067629557@sss.pgh.pa.us> User-Agent: Mutt/1.3.28i X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200311/7 X-Sequence-Number: 10995 On Fri, Oct 31, 2003 at 02:45:57PM -0500, Tom Lane wrote: > Lather, rinse, repeat until it comes up ... > Ok. That excercise was certainly no fun. For the various system tables I was missing, I managed to either find them in lost+found, or I copied the version from template0. The files for some relatively unimportant tables were irrecoverably destroyed. Of course, I realize that my database is probably now in a percarious state. I want to run a pg_dump, drop the db, and then rebuild into a fresh database. Except for selects on the destroyed tables, my database works as normal, so I'm confident I can get my data out. But pg_dump refuses to run. It complains about the destroyed tables and also something about plpgsql: pg_dump: NOTICE: RelationBuildDesc: can't open deprecated_data1: No such file or directory pg_dump: NOTICE: RelationBuildDesc: can't open unimportant_stuff: No such file or directory pg_dump: handler procedure for procedural language plpgsql not found I can't drop the tables from psql: drop TABLE deprecated_data1 ; ERROR: cannot open deprecated_data1: No such file or directory Am I likely to have success by performing surgery on the pg_table relation in order to remove these destroyed tables? Any hints on what I should do about the procedural language issue? -- Brian Ristuccia