Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 935BB632B79 for ; Fri, 7 May 2010 21:10:03 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 07482-07 for ; Sat, 8 May 2010 00:09:49 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from glacier.frostconsultingllc.com (glacier.frostconsultingllc.com [69.36.227.170]) by mail.postgresql.org (Postfix) with ESMTP id 82F02632778 for ; Fri, 7 May 2010 21:09:50 -0300 (ADT) Received: from dsl081-245-111.sfo1.dsl.speakeasy.net ([64.81.245.111] helo=Sidney-Stratton.local) by glacier.frostconsultingllc.com with esmtpsa (TLSv1:CAMELLIA256-SHA:256) (Exim 4.69) (envelope-from ) id 1OAXc1-0000JC-Pz; Fri, 07 May 2010 17:09:48 -0700 Message-ID: <4BE4ABC9.6040106@agliodbs.com> Date: Fri, 07 May 2010 17:09:45 -0700 From: Josh Berkus User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.1b3pre) Gecko/20090223 Thunderbird/3.0b2 MIME-Version: 1.0 To: pgsql-performance@postgresql.org CC: Jignesh Shah Subject: 8K recordsize bad on ZFS? Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201005/30 X-Sequence-Number: 38614 Jignesh, All: Most of our Solaris users have been, I think, following Jignesh's advice from his benchmark tests to set ZFS page size to 8K for the data zpool. However, I've discovered that this is sometimes a serious problem for some hardware. For example, having the recordsize set to 8K on a Sun 4170 with 8 drives recently gave me these appalling Bonnie++ results: Version 1.96 ------Sequential Output------ --Sequential Input- --Random- Concurrency 4 -Per Chr- --Block-- -Rewrite- -Per Chr- --Block-- --Seeks-- Machine Size K/sec %CP K/sec %CP K/sec %CP K/sec %CP K/sec %CP /sec %CP db111 24G 260044 33 62110 17 89914 15 1167 25 Latency 6549ms 4882ms 3395ms 107ms I know that's hard to read. What it's saying is: Seq Writes: 260mb/s combined Seq Reads: 89mb/s combined Read Latency: 3.3s Best guess is that this is a result of overloading the array/drives with commands for all those small blocks; certainly the behavior observed (stuttering I/O, latency) is in line with that issue. Anyway, since this is a DW-like workload, we just bumped the recordsize up to 128K and the performance issues went away ... reads up over 300mb/s. -- -- Josh Berkus PostgreSQL Experts Inc. http://www.pgexperts.com