From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Mark Kirkwood <markir(at)paradise(dot)net(dot)nz> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: fsync = true beneficial on ext3? |
Date: | 2004-02-09 04:18:30 |
Message-ID: | 20040209041830.GA13045@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Mon, Feb 09, 2004 at 03:13:08PM +1300, Mark Kirkwood wrote:
> FYI - Ext3 has 3 modes :
>
> data=ordered(default) : metadata is journaled (at write time data is
> written before metadata - i.e ordered)
> data=journal: data and metadata are journaled
> data=writeback: metadata journaled (no ordering at write time)
Thanks for that.
> The default will not help to protect database integrity if fsync is
> false (as only metadata is journaled)
>
> Will data=journal mode help? I am uncertain. A casual reading if these
> definitions suggests that it *might* - anyone know for sure?
My problem is that journalling works on a per-file basis. ie, the data for a
file is written before that file's metadata. However, the fsync is used for
the WAL segments and if you can't guarentee the WAL will hit the disk before
the data segments (different files), you're stuffed I think.
Or maybe WAL is not that sensitive to that kind of reordering. Maybe it only
depends on the WAL being consistant.
Hope this helps,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> (... have gone from d-i being barely usable even by its developers
> anywhere, to being about 20% done. Sweet. And the last 80% usually takes
> 20% of the time, too, right?) -- Anthony Towns, debian-devel-announce
From | Date | Subject | |
---|---|---|---|
Next Message | Marc G. Fournier | 2004-02-09 04:52:13 | Re: Fwd: Favorite DB poll on ORA |
Previous Message | Kris Jurka | 2004-02-09 02:40:11 | Re: PostgreSQL 7.4.1 and pgdb.py |