Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id 4C5C39FB3AE for ; Tue, 31 Oct 2006 16:11:42 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 28750-02 for ; Tue, 31 Oct 2006 20:11:02 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey- Received: from nz-out-0102.google.com (nz-out-0102.google.com [64.233.162.206]) by postgresql.org (Postfix) with ESMTP id 9C3AA9FB3DF for ; Tue, 31 Oct 2006 16:11:02 -0400 (AST) Received: by nz-out-0102.google.com with SMTP id i11so1683127nzi for ; Tue, 31 Oct 2006 12:11:01 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=lXEVi6HjJSTlFajFsqdTCvyHhPlG02F9E4hkuOJs5K4Q8p4Bnrp0S6VVttIX0o9RQmTfxUEW2WFxJSdxto7xtgYK5DA/F5lB/9CCf0b4daFBYAyKk96NfRuiQ1UCrv4ErscHfplD9kx9yHFQjoC9xpMeWxdL7B2DdrxkbPqHdzo= Received: by 10.35.119.11 with SMTP id w11mr7429287pym; Tue, 31 Oct 2006 12:11:01 -0800 (PST) Received: by 10.35.49.10 with HTTP; Tue, 31 Oct 2006 12:11:00 -0800 (PST) Message-ID: Date: Tue, 31 Oct 2006 16:11:00 -0400 From: "Worky Workerson" To: "Luke Lonergan" Subject: Re: Best COPY Performance Cc: pgsql-performance@postgresql.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200610/627 X-Sequence-Number: 21756 > > And here are the dd results for 16GB RAM, i.e. 4,000,000 8K blocks: > > So, if we divide 32,000 MB by the real time, we get: > /data (data): > 89 MB/s write > 38 MB/s read ... snip ... > The read speed on your /data volume is awful to the point where you should > consider it broken and find a fix. A quick comparison: the same number on a > 16 drive internal SATA array with 7200 RPM disks gets 950 MB/s read, about > 25 times faster for about 1/4 the price. I managed to get approval to shut down the Oracle instance and reran the dd's on the SAN (/data) and came up with about 60MB/s write (I had missed the 'sync' in the previous runs) and about 58 MB/s read, still no comparison on your SATA arrary. Any recommendations on what to look at to find a fix? One thing which I never mentioned was that I am using ext3 mounted with noatime,data=writeback. An interesting note (at least to me) is the inverse relationship between free memory and bo when writing with dd, i.e: $ vmstat 5 r b swpd free buff cache si so bi bo in cs us sy id wa 0 3 244664 320688 23588 15383120 0 0 0 28 1145 197 0 1 74 25 2 6 244664 349488 22276 15204980 0 0 0 24 1137 188 0 1 75 25 2 6 244664 28264 23024 15526552 0 0 0 65102 1152 335 0 12 60 28 2 4 244664 28968 23588 15383120 0 0 1 384386 1134 372 0 19 34 47 1 5 244664 28840 23768 15215728 0 0 1 438482 1144 494 0 24 33 43 0 5 247256 41320 20144 15212788 0 524 0 57062 1142 388 0 6 43 51 1 6 247256 29096 19588 15226788 0 0 5 60999 1140 391 0 15 42 43 Is this because of the kernel attempting to cache the file in memory?