X-Original-To: pgsql-performance@postgresql.org Received: from spampd.localdomain (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 06564474E42 for ; Thu, 10 Apr 2003 10:40:17 -0400 (EDT) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by postgresql.org (Postfix) with ESMTP id BF5BB4762A2 for ; Thu, 10 Apr 2003 10:40:15 -0400 (EDT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.9/8.12.9) with ESMTP id h3AEeF2L004073; Thu, 10 Apr 2003 10:40:15 -0400 (EDT) To: Jean-Luc Lachance Cc: jim@nasby.net, "scott.marlowe" , Matthew Nuzum , "'Josh Berkus'" , "'Pgsql-Performance'" Subject: Re: Caching (was Re: choosing the right platform) In-reply-to: <3E957F44.A1106F6A@nsd.ca> References: <00a001c2febb$631141d0$6900a8c0@mattspc> <20030409184744.W31861@flake.decibel.org> <11732.1049934037@sss.pgh.pa.us> <3E957F44.A1106F6A@nsd.ca> Comments: In-reply-to Jean-Luc Lachance message dated "Thu, 10 Apr 2003 10:27:16 -0400" Date: Thu, 10 Apr 2003 10:40:15 -0400 Message-ID: <4072.1049985615@sss.pgh.pa.us> From: Tom Lane X-Spam-Status: No, hits=-29.3 required=5.0 tests=BAYES_01,EMAIL_ATTRIBUTION,IN_REP_TO,REFERENCES, REPLY_WITH_QUOTES autolearn=ham version=2.50 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) X-Archive-Number: 200304/108 X-Sequence-Number: 1614 Jean-Luc Lachance writes: > Shouldn't there be a way to lock some tables in PG cache? In my opinion, no. I do not think a manual locking feature could possibly be used effectively. It could very easily be abused to decrease net performance, though :-( It does seem that a smarter buffer management algorithm would be a good idea, but past experiments have failed to show any measurable benefit. Perhaps those experiments were testing the wrong conditions. I'd still be happy to see LRU(k) or some such method put in, if someone can prove that it actually does anything useful for us. (As best I recall, I only tested LRU-2 with pgbench. Perhaps Josh's benchmarking project will offer a wider variety of interesting scenarios.) regards, tom lane