X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 41EEB9DC944 for ; Mon, 9 Jan 2006 14:54:51 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 84911-04 for ; Mon, 9 Jan 2006 14:54:50 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey- Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.193]) by postgresql.org (Postfix) with ESMTP id 909679DC835 for ; Mon, 9 Jan 2006 14:54:48 -0400 (AST) Received: by xproxy.gmail.com with SMTP id s14so2571026wxc for ; Mon, 09 Jan 2006 10:54:49 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type; b=Yjuflp2qdI4yPL7zFLpR3kELXbj4qEEtoTCVT75E10wHrCmi57+6eyLv3q1Tp126a4h83QhBnkXC8vEdoQyoskHbjXSZnery/PXnMFkL226WeMRJOlshSZ6ye1sBx/6FfccA0/TF7HJIrdp3jOPUAXrGvLfKVkCcARmC9Yb2Kec= Received: by 10.70.15.12 with SMTP id 12mr5467937wxo; Mon, 09 Jan 2006 10:54:49 -0800 (PST) Received: by 10.70.84.7 with HTTP; Mon, 9 Jan 2006 10:54:48 -0800 (PST) Message-ID: <1d219a6f0601091054q70283291v9deba2cb3c7b8fe@mail.gmail.com> Date: Mon, 9 Jan 2006 13:54:48 -0500 From: Chris Hoover To: "pgsql-admin@postgresql.org" , pgsql-performance@postgresql.org Subject: Memory Usage Question MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_84319_23632822.1136832888923" X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.431 required=5 tests=[AWL=-0.212, HTML_00_10=0.642, HTML_MESSAGE=0.001] X-Spam-Score: 0.431 X-Spam-Level: X-Archive-Number: 200601/96 X-Sequence-Number: 20184 ------=_Part_84319_23632822.1136832888923 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Question, How exactly is Postgres and Linux use the memory? I have serveral databases that have multi GB indexes on very large tables. On our current servers, the indexes can fit into memory but not the data (servers have 8 - 12 GB). However, my boss is wanting to get new servers for me but does not want to keep the memory requirements as high as they ar= e now (this will allow us to get more servers to spread our 200+ databases over). Question, if I have a 4GB+ index for a table on a server with 4GB ram, and = I submit a query that does an index scan, does Postgres read the entire index= , or just read the index until it finds the matching value (our extra large indexes are primary keys). I am looking for real number to give to my boss the say either having a primary key larger than our memory is bad (and how to clearly justfify it), or it is ok. If it is ok, what are the trade offs in performance?\ Obviously, I want more memory, but I have to prove the need to my boss sinc= e it raises the cost of the servers a fair amount. Thanks for any help, Chris ------=_Part_84319_23632822.1136832888923 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Question,

How exactly is Postgres and Linux use the memory?

I have serveral databases that have multi GB indexes on very large tables.  On our current servers, the indexes can fit into memory but not the data (servers have 8 - 12 GB).  However, my boss is wanting to get new servers for me but does not want to keep the memory requirements as high as they are now (this will allow us to get more servers to spread our 200+ databases over).

Question, if I have a 4GB+ index for a table on a server with 4GB ram, and I submit a query that does an index scan, does Postgres read the entire index, or just read the index until it finds the matching value (our extra large indexes are primary keys).

I am looking for real number to give to my boss the say either having a primary key larger than our memory is bad (and how to clearly justfify it), or it is ok.

If it is ok, what are the trade offs in performance?\

Obviously, I want more memory, but I have to prove the need to my boss sinc= e it raises the cost of the servers a fair amount.

Thanks for any help,

Chris
------=_Part_84319_23632822.1136832888923--