X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 0D4233A4ABA for ; Fri, 26 Nov 2004 19:04:40 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 15007-06 for ; Fri, 26 Nov 2004 19:04:38 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id 3CC7E3A49EC for ; Fri, 26 Nov 2004 19:04:37 +0000 (GMT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id iAQJ4ZYT010505; Fri, 26 Nov 2004 14:04:36 -0500 (EST) To: "David Parker" Cc: pgsql-performance@postgresql.org Subject: Re: time to stop tuning? In-reply-to: <07FDEE0ED7455A48AC42AC2070EDFF7C26BDD2@corpsrv2.tazznetworks.com> References: <07FDEE0ED7455A48AC42AC2070EDFF7C26BDD2@corpsrv2.tazznetworks.com> Comments: In-reply-to "David Parker" message dated "Fri, 26 Nov 2004 12:13:32 -0500" Date: Fri, 26 Nov 2004 14:04:35 -0500 Message-ID: <10504.1101495875@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200411/407 X-Sequence-Number: 9361 "David Parker" writes: > 1) Given that the data is all cached, what can we do to make sure that > postgres is generating the most efficient plans in this case? We have > bumped up effective_cache_size, but it had no effect. If you're willing to bet on everything being in RAM all the time, dropping random_page_cost to 1 would be a theoretically sound thing to do. In any case you should look at reducing it considerably from the default setting of 4. Something that might also be interesting is to try increasing all the cpu_xxx cost factors, on the theory that since the unit of measurement (1 sequential page fetch) relates to an action involving no actual I/O, the relative costs of invoking an operator, etc, should be rated higher than when you expect actual I/O. I'm not real confident that this would make things better --- you might find that any improvement would be swamped by the low accuracy with which we model CPU costs (such as the assumption that every operator costs the same to evaluate). But it's worth some experimentation. regards, tom lane