Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id C556C1337B9A for ; Thu, 23 Dec 2010 14:05:26 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 90223-03 for ; Thu, 23 Dec 2010 18:05:19 +0000 (UTC) X-Greylist: delayed 00:22:27.624658 by SQLgrey-1.7.6 Received: from proofpoint1.lanl.gov (proofpoint1.lanl.gov [204.121.3.25]) by mail.postgresql.org (Postfix) with ESMTP id 514CE13364DE for ; Thu, 23 Dec 2010 14:05:19 -0400 (AST) Received: from mailrelay1.lanl.gov (mailrelay1.lanl.gov [128.165.4.101]) by proofpoint1 (8.14.3/8.14.3) with ESMTP id oBNHbrpZ002185 for ; Thu, 23 Dec 2010 10:42:48 -0700 Received: from nis-mail.lanl.gov (nis-mail.lanl.gov [128.165.4.121]) by mailrelay1.lanl.gov (Postfix) with ESMTP id DAD03152FEC for ; Thu, 23 Dec 2010 10:37:53 -0700 (MST) Received: from localhost (localhost.localdomain [127.0.0.1]) by nis-mail.lanl.gov (Postfix) with ESMTP id D8886DC00B2 for ; Thu, 23 Dec 2010 10:37:53 -0700 (MST) X-NIE-2-Virus-Scanner: amavisd-new at nis-mail.lanl.gov Received: from [128.165.202.190] (procyon.lanl.gov [128.165.202.190]) by nis-mail.lanl.gov (Postfix) with ESMTP id C97A1DC00A7 for ; Thu, 23 Dec 2010 10:37:53 -0700 (MST) Subject: concurrent IO in postgres? From: Przemek Wozniak Reply-To: wozniak@lanl.gov To: pgsql-performance@postgresql.org Content-Type: text/plain Organization: LANL Date: Thu, 23 Dec 2010 10:37:53 -0700 Message-Id: <1293125873.3685.91.camel@procyon.lanl.gov> Mime-Version: 1.0 X-Mailer: Evolution 2.22.1 (2.22.1-2.fc9) Content-Transfer-Encoding: 7bit X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.2.15, 1.0.148, 0.0.0000 definitions=2010-12-23_08:2010-12-23, 2010-12-23, 1970-01-01 signatures=0 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-6.91 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201012/294 X-Sequence-Number: 41746 When testing the IO performance of ioSAN storage device from FusionIO (650GB MLC version) one of the things I tried is a set of IO intensive operations in Postgres: bulk data loads, updates, and queries calling for random IO. So far I cannot make Postgres take advantage of this tremendous IO capacity. I can squeeze a factor of a few here and there when caching cannot be utilized, but this hardware can do a lot more. Low level testing with fio shows on average x10 speedups over disk for sequential IO and x500-800 for random IO. With enough threads I can get IOPS in the 100-200K range and 1-1.5GB/s bandwidth, basically what's advertised. But not with Postgres. Is this because the Postgres backend is essentially single threaded and in general does not perform asynchronous IO, or I'm missing something? I found out that the effective_io_concurrency parameter only takes effect for bitmap index scans. Also, is there any work going on to allow concurrent IO in the backend and adapt Postgres to the capabilities of Flash? Will appreciate any comments, experiences, etc. Przemek Wozniak