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 C4A5AD1BC76 for ; Mon, 17 Nov 2003 19:57:53 +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 39339-01 for ; Mon, 17 Nov 2003 15:57:24 -0400 (AST) Received: from megazone.bigpanda.com (megazone.bigpanda.com [64.147.171.210]) by svr1.postgresql.org (Postfix) with ESMTP id 055FAD1BB48 for ; Mon, 17 Nov 2003 15:57:23 -0400 (AST) Received: by megazone.bigpanda.com (Postfix, from userid 1001) id 8428F352A7; Mon, 17 Nov 2003 11:57:23 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by megazone.bigpanda.com (Postfix) with ESMTP id 8302035129; Mon, 17 Nov 2003 11:57:23 -0800 (PST) Date: Mon, 17 Nov 2003 11:57:23 -0800 (PST) From: Stephan Szabo To: Jeff Cc: oneway_111@yahoo.com, pgsql-admin@postgresql.org Subject: Re: pg_restore and FK constraints with large dbs In-Reply-To: <20031117144703.138edb9f.threshar@torgo.978.org> Message-ID: <20031117115549.A1602@megazone.bigpanda.com> References: <20031117041435.13499.qmail@web21402.mail.yahoo.com> <20031117103655.W99532@megazone.bigpanda.com> <20031117144703.138edb9f.threshar@torgo.978.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200311/317 X-Sequence-Number: 11304 On Mon, 17 Nov 2003, Jeff wrote: > On Mon, 17 Nov 2003 10:40:20 -0800 (PST) > Stephan Szabo wrote: > > > > > By the way, what does your schema look like? I created an 80M row fk > > table and 20K row pk table with an int4 key between them and indexes on > > the two key fields. It took about 25 minutes on my not terribly fast > > system using 7.4b5 to make the foreign key between them. It might have > > been faster if I'd raised sort_mem to something larger than 8192. > > > > i missed the start of this thread... but unless you are running 7.4 > adding an FK (restore) is very slow. ZIt is fixed in 7.4.. especially > w/lots of sort mem. Yeah. At the start of the discussion I believe 7.4RC2 was mentioned as the version which is why I'm surprised at the difference in times.