Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 82EEB6325DE for ; Thu, 14 Jan 2010 16:19:09 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 65486-08 for ; Thu, 14 Jan 2010 20:18:55 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-fx0-f220.google.com (mail-fx0-f220.google.com [209.85.220.220]) by mail.postgresql.org (Postfix) with ESMTP id 8983463EEE4 for ; Thu, 14 Jan 2010 16:18:58 -0400 (AST) Received: by fxm20 with SMTP id 20so709923fxm.35 for ; Thu, 14 Jan 2010 12:18:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:received:date:from:to:cc :subject:message-id:references:mime-version:content-type :content-disposition:in-reply-to:user-agent; bh=szGqRSrOr+/lnOKu+K0ONNRi6fA0Cu3G/Op46h49aJI=; b=cVXimJ9U8WiGr3HrNY9WKNSSQWsJM4Qa+9YAJJ6hl3Y76nOXykiv+mV7m8wfn3OfA/ +1oc1zGfDCSIn94NUf3qpMCQuhoHW7/OF4amqu+uz0dl+IxL/dtfTwk4gvKx8WZu3JbG fy06wIwHDnRk2nUzZiygPXGgmRxFG8kHRlegc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; b=BkV2tMkV85A0XNNvp0VOCkqE+kedA7cswYXnlnk3qHZh58V90fJD+leUkVI1Jq4SOr lJf0lKU4NerYVBWwTzSnd+kzIeIWSqF2/HdZDQEuObsgvTgUH/vFvUuB8slnvCjPwV+c 1a1BFx8c8PF+XMr41t5OsDxZceXyPBAgw2mOA= Received: by 10.223.81.76 with SMTP id w12mr1686845fak.1.1263500336683; Thu, 14 Jan 2010 12:18:56 -0800 (PST) Received: from googlemail.com (port-87-193-148-114.static.qsc.de [87.193.148.114]) by mx.google.com with ESMTPS id 13sm585197fxm.5.2010.01.14.12.18.55 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 14 Jan 2010 12:18:56 -0800 (PST) Received: by googlemail.com (nbSMTP-1.00) for uid 1100 (using TLSv1/SSLv3 with cipher RC4-MD5 (128/128 bits)) fkater@googlemail.com; Thu, 14 Jan 2010 21:18:56 +0100 (CET) Date: Thu, 14 Jan 2010 21:18:54 +0100 From: "fkater@googlemail.com" To: Matthew Wakeling Cc: pgsql-performance@postgresql.org Subject: Re: Inserting 8MB bytea: just 25% of disk perf used? Message-ID: <20100114201854.GC2384@comppasch2> References: <20100114142903.GB2973@comppasch2> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.599 tagged_above=-10 required=5 tests=BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 201001/306 X-Sequence-Number: 37186 Thanks a lot for the detailed reply. Matthew Wakeling: > On Thu, 14 Jan 2010, fkater@googlemail.com wrote: > > This takes about 50s, so, 800MB/50s = 16MB/s. > > > > However the harddisk (sata) could write 43 MB/s in the worst > > case! Why is write performance limited to 16 MB/s? > > Several reasons: > > The data needs to be written first to the WAL, in order to provide > crash-safety. So you're actually writing 1600MB, not 800. I understand. So the actual throughput is 32MB/s which is closer to 43 MB/s, of course. Can I verify that by temporarily disabling WAL writes completely and see if the thoughput is then doubled? Felix