From: Andres Freund <andres@anarazel.de>
To: pgsql-performance@postgresql.org
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Marc Cousin <cousinmarc@gmail.com>
Subject: Re: performance regression with Linux 2.6.33 and glibc 2.12
Date: Fri, 4 Jun 2010 17:25:05 +0200
Message-ID: <201006041725.06308.andres@anarazel.de> (raw)
In-Reply-To: <2135.1275659945@sss.pgh.pa.us>
References: <201006041539.03868.cousinmarc@gmail.com>
<2135.1275659945@sss.pgh.pa.us>
On Friday 04 June 2010 15:59:05 Tom Lane wrote:
> Marc Cousin <cousinmarc@gmail.com> writes:
> > I hope I'm not going to expose an already known problem, but I couldn't
> > find it mailing list archives (I only found
> > http://archives.postgresql.org/pgsql- hackers/2009-12/msg01543.php).
>
> You sure this isn't the well-known "ext4 actually implements fsync
> where ext3 didn't" issue?
I doubt it. It reads to me like he is testing the two methods on the same
installation with the same kernel
> > with wal_sync_method = open_datasync (new default)
> > marc=# INSERT INTO test SELECT generate_series(1,100000);
> > INSERT 0 100000
> > Time: 16083,912 ms
> >
> > with wal_sync_method = fdatasync (old default)
> >
> > marc=# INSERT INTO test SELECT generate_series(1,100000);
> > INSERT 0 100000
> > Time: 954,000 ms
Its not actually surprising that in such a open_datasync is hugely slower than
fdatasync. With open_datasync every single write will be synchronous, very
likely not reordered/batched/whatever. In contrast to that with fdatasync it
will only synced in way much bigger batches.
Or am I missing something?
I always thought the synchronous write methods to be a fallback kludge and
didnt realize its actually the preferred method...
Andres
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: andres@anarazel.de, tgl@sss.pgh.pa.us, cousinmarc@gmail.com
Subject: Re: performance regression with Linux 2.6.33 and glibc 2.12
In-Reply-To: <201006041725.06308.andres@anarazel.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox