fsync on 7.1

Started by Joseph Shraibmanalmost 25 years ago3 messagesgeneral
Jump to latest
#1Joseph Shraibman
jks@selectacast.net

If I turn off fsync on 7.1 does that mean that the wal file is sync'd
(according to WAL_SYNC_METHOD in the log file) and other files are not?
Or does fsync apply to all file equally?

--
Joseph Shraibman
jks@selectacast.net
Increase signal to noise ratio. http://www.targabot.com

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Joseph Shraibman (#1)
Re: fsync on 7.1

Joseph Shraibman <jks@selectacast.net> writes:

If I turn off fsync on 7.1 does that mean that the wal file is sync'd
(according to WAL_SYNC_METHOD in the log file) and other files are not?
Or does fsync apply to all file equally?

The latter. Note where the docs say:

The WAL_SYNC_METHOD parameter determines how Postgres will ask the
kernel to force WAL updates out to disk. All the options should be the
same as far as reliability goes, but it's quite platform-specific which
one will be the fastest. Note that this parameter is irrelevant if FSYNC
has been turned off.

regards, tom lane

#3Joseph Shraibman
jks@selectacast.net
In reply to: Joseph Shraibman (#1)
Re: fsync on 7.1

Tom Lane wrote:

Joseph Shraibman <jks@selectacast.net> writes:

If I turn off fsync on 7.1 does that mean that the wal file is sync'd
(according to WAL_SYNC_METHOD in the log file) and other files are not?
Or does fsync apply to all file equally?

The latter. Note where the docs say:

The WAL_SYNC_METHOD parameter determines how Postgres will ask the
kernel to force WAL updates out to disk. All the options should be the
same as far as reliability goes, but it's quite platform-specific which
one will be the fastest. Note that this parameter is irrelevant if FSYNC
has been turned off.

regards, tom lane

Err... where is that? I'm looking at
/usr/local/pgsql/doc/html/runtime-config.html#RUNTIME-CONFIG-WAL

--
Joseph Shraibman
jks@selectacast.net
Increase signal to noise ratio. http://www.targabot.com