Received: from maia.hub.org (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 840D0632CB9 for ; Fri, 15 Jan 2010 01:17:31 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 54506-07 for ; Fri, 15 Jan 2010 05:17:20 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.17.9]) by mail.postgresql.org (Postfix) with ESMTP id 702B9632C94 for ; Fri, 15 Jan 2010 01:17:20 -0400 (AST) Received: from [192.168.1.3] (pool-96-244-14-10.bltmmd.fios.verizon.net [96.244.14.10]) by mrelayeu.kundenserver.de (node=mrbap0) with ESMTP (Nemesis) id 0MKbbD-1NTjPn20s3-001St9; Fri, 15 Jan 2010 06:17:18 +0100 Message-ID: <4B4FFA5B.8000901@2ndquadrant.com> Date: Fri, 15 Jan 2010 00:17:15 -0500 From: Greg Smith User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: Carlo Stonebanks CC: pgsql-performance@postgresql.org Subject: Re: New server to improve performance on our large and busy DB - advice? References: In-Reply-To: Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V01U2FsdGVkX1+sIUQXp7umm77w1oyxK55ARUKYCyLhhdg2qpz DrOMkwwZKg3/NwVmtLp5JTkIWn5EGZsZICOJrGdg9Aku4FD+VZ uSkJP/TGGiQaqljGwUrz2itiA7b8/uq X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.589 tagged_above=-10 required=5 tests=BAYES_00=-2.599, FH_DATE_PAST_20XX=3.188 X-Spam-Level: X-Archive-Number: 201001/322 X-Sequence-Number: 37202 Carlo Stonebanks wrote: > 1) Which RAID level would you recommend It looks like you stepped over a critical step, which is "will the server have a good performing RAID card?". Your whole upgrade could underperform if you make a bad mistake on that part. It's really important to nail that down, and to benchmark to prove you got what you expected from your hardware vendor. > 3) If we were to port to a *NIX flavour, which would you recommend? > (which support trouble-free PG builds/makes please!) The only platform I consider close to trouble free as far as the PG builds working without issues are RHEL/CentOS, due to the maturity of the PGDG yum repository and how up to date it's kept. Every time I wander onto another platform I find the lag and care taken in packaging PostgreSQL to be at least a small step down from there. > 4) Is this the right PG version for our needs? 8.4 removes the FSM, which takes away a common source for unexpected performance issues when you overflow max_fsm_pages one day. If you're going to deploy 8.3, you need to be more careful to monitor the whole VACUUM process; it's easier to ignore in 8.4 and still get by OK. As far as general code stability goes, I think it's a wash at this point. You might discover a bug in 8.4 that causes a regression, but I think you're just as likely to run into a situation that 8.3 handles badly that's improved in 8.4. Hard to say which will work out better in a really general way. > . We believe our requirements are exceptional, and we would benefit > immensely from setting up the PG planner to always favour > index-oriented decisions - which seems to contradict everything that > PG advice suggests as best practice. Pretty much everyone thinks their requirements are exceptional. It's funny how infrequently that's actually true. The techniques that favor index-use aren't that unique: collect better stats, set basic parameters correctly, adjust random_page_cost, investigate plans that don't do what you want to figure out why. It's easy to say there's something special about your data rather than follow fundamentals here; I'd urge you to avoid doing that. The odds that the real issue is that you're feeding the optimizer bad data is more likely than most people think, which brings us to: > Current non-default conf settings are: I don't see effective_cache_size listed there. If that's at the default, I wouldn't be surprised that you're seeing sequential scans instead of indexed ones far too often. > max_connections = 200 > work_mem = 512MB This is a frightening combination by the way. -- Greg Smith 2ndQuadrant Baltimore, MD PostgreSQL Training, Services and Support greg@2ndQuadrant.com www.2ndQuadrant.com