Skip site navigation (1) Skip section navigation (2)

Re: Defaulting wal_sync_method to fdatasync on Linux for 9.1?

From: Andres Freund <andres(at)anarazel(dot)de>
To: pgsql-performance(at)postgresql(dot)org
Cc: Greg Smith <greg(at)2ndquadrant(dot)com>, Marti Raudsepp <marti(at)juffo(dot)org>
Subject: Re: Defaulting wal_sync_method to fdatasync on Linux for 9.1?
Date: 2010-10-31 23:10:28
Message-ID: 201011010010.28724.andres@anarazel.de (view raw or flat)
Thread:
Lists: pgsql-performance
On Sunday 31 October 2010 20:59:31 Greg Smith wrote:
> Writes only are sync'd out when you do a commit, or the database does a 
> checkpoint.
Hm?  WAL is written out to disk after an the space provided by wal_buffers(def 
8) * XLOG_BLCKSZ (def 8192) is used. The default is 64kb which you reach 
pretty quickly - especially after a checkpoint. With O_D?SYNC that will 
synchronously get written out during a normal XLogInsert if hits a page 
boundary.
*Additionally* its gets written out at a commit if sync commit is not on.

Not having a real O_DSYNC on linux until recently makes it even more dubious 
to have it as a default...


Andres

In response to

Responses

pgsql-performance by date

Next:From: Marti RaudseppDate: 2010-11-01 01:29:41
Subject: Re: Defaulting wal_sync_method to fdatasync on Linux for 9.1?
Previous:From: Greg SmithDate: 2010-10-31 19:59:31
Subject: Re: Defaulting wal_sync_method to fdatasync on Linux for 9.1?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group