X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id EEF84D1E966; Thu, 18 Mar 2004 20:34:45 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 06132-07; Thu, 18 Mar 2004 16:34:44 -0400 (AST) Received: from candle.pha.pa.us (candle.pha.pa.us [207.106.42.251]) by svr1.postgresql.org (Postfix) with ESMTP id 891FCD1E2AA; Thu, 18 Mar 2004 16:34:34 -0400 (AST) Received: (from pgman@localhost) by candle.pha.pa.us (8.11.6/8.11.6) id i2IKYLp27844; Thu, 18 Mar 2004 15:34:21 -0500 (EST) From: Bruce Momjian Message-Id: <200403182034.i2IKYLp27844@candle.pha.pa.us> Subject: Re: [HACKERS] fsync method checking In-Reply-To: <20040318202621.GB8330@ping.be> To: Kurt Roeckx Date: Thu, 18 Mar 2004 15:34:21 -0500 (EST) Cc: Tom Lane , Mark Kirkwood , pgsql-performance@postgresql.org, PostgreSQL-development X-Mailer: ELM [version 2.4ME+ PL108 (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200403/267 X-Sequence-Number: 6123 Kurt Roeckx wrote: > Here are my results on Linux 2.6.1 using cvs version 1.7. > > Those times with > 20 seconds, you really hear the disk go crazy. > > And I have the feeling something must be wrong. Those results > are reproducible. > Wow, your O_SYNC times are great. Where can I buy some? :-) Anyway, we do need to find a way to test this because obviously there is huge platform variability. --------------------------------------------------------------------------- > > Kurt > > > Simple write timing: > write 0.139558 > > Compare fsync times on write() and non-write() descriptor: > (If the times are similar, fsync() can sync data written > on a different descriptor.) > write, fsync, close 8.249364 > write, close, fsync 8.356813 > > Compare one o_sync write to two: > one 16k o_sync write 28.487650 > two 8k o_sync writes 2.310304 > > Compare file sync methods with one 8k write: > (o_dsync unavailable) > open o_sync, write 1.010688 > write, fdatasync 25.109604 > write, fsync, 26.051218 > > Compare file sync methods with 2 8k writes: > (The fastest should be used for wal_sync_method) > (o_dsync unavailable) > open o_sync, write 2.212223 > write, fdatasync 27.439907 > write, fsync, 27.772294 > > > ---------------------------(end of broadcast)--------------------------- > TIP 5: Have you checked our extensive FAQ? > > http://www.postgresql.org/docs/faqs/FAQ.html > -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 359-1001 + If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square, Pennsylvania 19073