X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 977ABD1B56A for ; Tue, 28 Oct 2003 19:22:36 +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 45775-08 for ; Tue, 28 Oct 2003 15:22:06 -0400 (AST) Received: from lorax.kcilink.com (lorax.kciLink.com [206.112.95.1]) by svr1.postgresql.org (Postfix) with ESMTP id E6836D1B53E for ; Tue, 28 Oct 2003 15:22:04 -0400 (AST) Received: from localhost (localhost [127.0.0.1]) by lorax.kcilink.com (Postfix) with ESMTP id A0D1A3E8D for ; Tue, 28 Oct 2003 14:22:05 -0500 (EST) Received: from lorax.kcilink.com ([127.0.0.1]) by localhost (lorax.kcilink.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 17423-04-2 for ; Tue, 28 Oct 2003 14:22:05 -0500 (EST) Received: from lorax.kciLink.com (localhost [127.0.0.1]) by lorax.kcilink.com (Postfix) with ESMTP id 1423E3E67 for ; Tue, 28 Oct 2003 14:22:05 -0500 (EST) Received: (from news@localhost) by lorax.kciLink.com (8.12.9p2/8.12.9/Submit) id h9SJM5u9031436 for pgsql-performance@postgresql.org; Tue, 28 Oct 2003 14:22:05 -0500 (EST) (envelope-from news) To: pgsql-performance@postgresql.org Path: not-for-mail From: Vivek Khera Newsgroups: ml.postgres.performance Subject: Re: Adding foreign key performance Date: Tue, 28 Oct 2003 14:22:04 -0500 Organization: Khera Communications, Inc., Rockville, MD Lines: 30 Message-ID: References: <20031028091645.3d610841.threshar@torgo.978.org> NNTP-Posting-Host: yertle.kcilink.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: lorax.kcilink.com 1067368925 19562 216.194.193.105 (28 Oct 2003 19:22:05 GMT) X-Complaints-To: daemon@kciLink.com NNTP-Posting-Date: Tue, 28 Oct 2003 19:22:05 +0000 (UTC) User-Agent: Gnus/5.1002 (Gnus v5.10.2) XEmacs/21.4 (Portable Code, berkeley-unix) Cancel-Lock: sha1:LjEPHPFQj13MAOCly5EmPnt3/vM= X-Virus-Scanned: by amavisd-new at kciLink.com X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200310/716 X-Sequence-Number: 4464 >>>>> "J" == Jeff writes: J> And this leads to the place we'd get a huge benefit: Restoring J> backups.. If there were some way to bump up sort_mem while doing J> the restore.. things would be much more pleasant. [Although, even There was a rather substantial thread on this about the time when 7.4b1 was released. J> better would be to disable FK stuff while restoring a backup and J> assume the backup is "sane"] How we'd go about doing that is the J> subject of much debate. If you're restoring from a pg_dump -Fc (compressed dump) it already happens for you. The indexes and foreign keys are not added until the very end, from what I recall. J> Perhaps add the functionality to pg_restore? ie, pg_restore -s J> 256MB mybackup.db? It would just end up issuing a set J> sort_mem=256000.. This was essentially my proposal, though I had better speed enhancement by increasing the number of checkpoint buffers. -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Vivek Khera, Ph.D. Khera Communications, Inc. Internet: khera@kciLink.com Rockville, MD +1-240-453-8497 AIM: vivekkhera Y!: vivek_khera http://www.khera.org/~vivek/