From: Paolo Bonzini <pbonzini@redhat.com>
To: "Marcin Gibuła" <m.gibula@beyond.pl>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] migration question: disk images on nfs server
Date: Fri, 07 Feb 2014 13:26:57 +0100 [thread overview]
Message-ID: <52F4D111.1040200@redhat.com> (raw)
In-Reply-To: <52F4AA56.9020901@beyond.pl>
Il 07/02/2014 10:41, Marcin Gibuła ha scritto:
>> For NFS you need to use the sync mount option to force the NFS client to
>> sync to
>> server on writes.
>
> Isn't opening with O_DIRECT enough? (for linux nfs client at least)
Yeah, the man page says:
If neither sync nor async is specified (or
if the async option is specified), the NFS client delays sending appli‐
cation writes to the server until any of these events occur:
Memory pressure forces reclamation of system memory resources.
An application flushes file data explicitly with sync(2),
msync(2), or fsync(3).
An application closes a file with close(2).
The file is locked/unlocked via fcntl(2).
In other words, under normal circumstances, data written by an applica‐
tion may not immediately appear on the server that hosts the file.
QEMU does flush file data with fsync(3). It's not the first time I hear about
needing the sync option though.
Paolo
next prev parent reply other threads:[~2014-02-07 12:27 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-07 4:35 [Qemu-devel] migration question: disk images on nfs server Alexey Kardashevskiy
2014-02-07 7:46 ` Orit Wasserman
2014-02-07 9:41 ` Marcin Gibuła
2014-02-07 12:26 ` Paolo Bonzini [this message]
2014-02-07 12:10 ` Alexey Kardashevskiy
2014-02-07 12:47 ` Orit Wasserman
2014-02-07 12:54 ` Marcin Gibuła
2014-02-07 13:36 ` Orit Wasserman
2014-02-07 13:44 ` Marcin Gibuła
2014-02-07 13:57 ` Orit Wasserman
2014-02-08 8:30 ` Kevin Wolf
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=52F4D111.1040200@redhat.com \
--to=pbonzini@redhat.com \
--cc=m.gibula@beyond.pl \
--cc=qemu-devel@nongnu.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.