pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Guoping Zhang <guoping.zhang@nec.com.au>
To: 'Tom Lane' <tgl@sss.pgh.pa.us>
Cc: pgsql-performance@postgresql.org
Cc: 'Guoping Zhang (E-mail)' <guopingz@nstc.nec.com.au>
Subject: Re: how unsafe (or worst scenarios) when setting fsync OFF for postgresql
Date: Fri, 28 Apr 2006 15:58:06 +1000
Message-ID: <004901c66a88$b909edd0$74304c93@eddy> (raw)
In-Reply-To: <25291.1146200208@sss.pgh.pa.us>

Hi, Tom

Many thanks for quick replies and that helps a lot.

Just in case, anyone out there can recommend a good but cost effective
battery-backed write cache SCSI for Solaris SPARC platform? How well does it
work with UFS or newer ZFS for solaris?

Cheers and regards,
Guoping




-----Original Message-----
From: Tom Lane [mailto:tgl@sss.pgh.pa.us]
Sent: 2006Äê4ÔÂ28ÈÕ 14:57
To: guoping.zhang@nec.com.au
Cc: pgsql-performance@postgresql.org; 'Guoping Zhang (E-mail)'
Subject: Re: [PERFORM] how unsafe (or worst scenarios) when setting
fsync OFF for postgresql


"Guoping Zhang" <guoping.zhang@nec.com.au> writes:
> a) The tests consists of ten thousands very small transactions, which are
> not grouped, that is why so slow with compare to set fsync off.

Yup.

> c) wal_sync_method is set to 'open_datasync', which is fastest among the
> four, right?

Well, is it?  You shouldn't assume that without testing.

> Looks like, if we have to set fsync be true, we need to modify our
> application.

Yes, you should definitely look into batching your operations into
larger transactions.  On normal hardware you can't expect to commit
transactions faster than one per disk revolution (unless they're coming
from multiple clients, where there's a hope of ganging several parallel
commits per revolution).

Or buy a disk controller with battery-backed write cache and put your
faith in that cache surviving a machine crash.  But don't turn off fsync
if you care about your data.

			regards, tom lane




view thread (14+ messages)  latest in thread

Message-ID: <004901c66a88$b909edd0$74304c93@eddy>
Permalink:  ../004901c66a88$b909edd0$74304c93@eddy/
Also on:    postgresql.org/message-id/004901c66a88$b909edd0$74304c93@eddy

 · 

reply

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: guoping.zhang@nec.com.au, tgl@sss.pgh.pa.us, guopingz@nstc.nec.com.au
  Subject: Re: how unsafe (or worst scenarios) when setting fsync OFF for postgresql
  In-Reply-To: <004901c66a88$b909edd0$74304c93@eddy>

* 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