Re: Would it be OK if I put db file on a ext2 filesystem?

From: "Douglas McNaught" <doug(at)mcnaught(dot)org>
To: "Alvaro Herrera" <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: "Magicloud Wang" <magicloud(at)pogolinux(dot)com(dot)cn>, pgsql-general(at)postgresql(dot)org
Subject: Re: Would it be OK if I put db file on a ext2 filesystem?
Date: 2007-12-12 16:22:54
Message-ID: 5ded07e00712120822r4c0b5c78l997e6042188b1774@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 12/12/07, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> wrote:

> Regular database files need metadata journalling (data=writeback mount
> option for ext3). This is quite faster than full-blown journalling
> which is what you get with default ext3 mount options. WAL files
> (pg_xlog) do not need any kind of journalling, so you can save the
> overhead and put them on an ext2 filesystem (or any other nonjournalled
> filesystem).

I think in practice there won't be a performance difference between
ext3 with 'data=writeback' and ext2 for WAL-the files are
preallocated, so the only activity that's occurring with any frequency
is fsync'd data writes to existing file blocks, which don't go through
the journal. So you might as well go with ext3 since (a) you won't
have to fsck, and (b) ext3 is the bog-standard Linux filesystem now
and as such gets the most testing--ext2 is gradually dropping into
obsolescence.

-Doug

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Joshua D. Drake 2007-12-12 16:29:10 Re: Slow PITR restore
Previous Message Scott Marlowe 2007-12-12 16:17:24 Re: Would it be OK if I put db file on a ext2 filesystem?