Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id E1F559FA22C for ; Sat, 16 Dec 2006 13:32:28 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-new, port 10024) with ESMTP id 28909-06 for ; Sat, 16 Dec 2006 13:32:19 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from cassarossa.samfundet.no (cassarossa.samfundet.no [129.241.93.19]) by postgresql.org (Postfix) with ESMTP id CF2AE9FA274 for ; Sat, 16 Dec 2006 13:32:18 -0400 (AST) Received: from trofast.sesse.net ([129.241.93.32]) by cassarossa.samfundet.no with esmtp (Exim 4.50) id 1GvdOS-0002up-HQ; Sat, 16 Dec 2006 18:32:16 +0100 Received: from sesse by trofast.sesse.net with local (Exim 3.36 #1 (Debian)) id 1GvdOX-0006d7-00; Sat, 16 Dec 2006 18:32:21 +0100 Date: Sat, 16 Dec 2006 18:32:21 +0100 From: "Steinar H. Gunderson" To: tsuraan Cc: pgsql-performance@postgresql.org Subject: Re: Scaling concerns Message-ID: <20061216173221.GA25410@uio.no> Mail-Followup-To: tsuraan , pgsql-performance@postgresql.org References: <84fb38e30612160926l609ec55cs352b2495289bae0c@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <84fb38e30612160926l609ec55cs352b2495289bae0c@mail.gmail.com> X-Operating-System: Linux 2.6.19 on a x86_64 X-Message-Flag: Outlook? --> http://www.mozilla.org/products/thunderbird/ User-Agent: Mutt/1.5.13 (2006-08-11) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200612/440 X-Sequence-Number: 22496 On Sat, Dec 16, 2006 at 11:26:02AM -0600, tsuraan wrote: > Even an operation like "select count(*) from messages" can take minutes, > with a totally idle system. Postgres seems to be the most scalable Free > database out there, so I must be doing something wrong. Unqualified SELECT COUNT(*) FROM foo is one of the most expensive operations you can do on your system, since the visibility information has to be checked on disk for each row. Instead, try real queries on real data, and post here if some are too slow for you. /* Steinar */ -- Homepage: http://www.sesse.net/