public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Wietse Venema <wietse@porcupine.org>
Cc: Eric Sandeen <sandeen@sandeen.net>,
	Justin Piszcz <jpiszcz@lucidpixels.com>,
	Postfix users <postfix-users@postfix.org>,
	xfs@oss.sgi.com
Subject: Re: Which FileSystem do you use on your postfix server?
Date: Mon, 3 Nov 2008 08:44:45 +1100	[thread overview]
Message-ID: <20081102214444.GE19509@disturbed> (raw)
In-Reply-To: <20081031225615.5E66B1F3EA0@spike.porcupine.org>

On Fri, Oct 31, 2008 at 06:56:15PM -0400, Wietse Venema wrote:
> Dave Chinner:
> Here's something I would like to know regarding the order of
> directory updates:
> 
> - Does fsync(file) guarantee the file's directory entry is safe?

No.

> Some file systems complete directory updates before the open/link/rename
> system call returns, so fsync() doesn't have to worry about it.

If you run with '-o dirsync', all directory transactions are guaranteed
to be in the log on disk by the time the syscall returns. Note that
this means you do at least one log write per create/link/rename/unlink
syscall, which has performance impact....

> - Does rename() guarantee that at least one directory entry will
> exist even when the system crashes in the middle of the operation?

Yes - either it will complete atomically or no change will occur at
all.

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

      reply	other threads:[~2008-11-02 21:45 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20081031121002.D94A11F3E98@spike.porcupine.org>
2008-10-31 12:13 ` Which FileSystem do you use on your postfix server? Justin Piszcz
2008-10-31 13:32   ` Justin Piszcz
2008-10-31 14:56   ` Eric Sandeen
2008-10-31 15:37     ` Wietse Venema
2008-10-31 22:18       ` Dave Chinner
2008-10-31 22:56         ` Wietse Venema
2008-11-02 21:44           ` Dave Chinner [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20081102214444.GE19509@disturbed \
    --to=david@fromorbit.com \
    --cc=jpiszcz@lucidpixels.com \
    --cc=postfix-users@postfix.org \
    --cc=sandeen@sandeen.net \
    --cc=wietse@porcupine.org \
    --cc=xfs@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox