From: "Daniel P. Berrange" <berrange@redhat.com>
To: Stefan Hajnoczi <stefanha@redhat.com>
Cc: "Kevin Wolf" <kwolf@redhat.com>,
"Stefan Hajnoczi" <stefanha@gmail.com>,
"Alex Bennée" <alex.bennee@linaro.org>,
"Chunyan Liu" <cyliu@suse.com>,
qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] qemu-img: set nocow flag to new file
Date: Wed, 18 Dec 2013 14:24:11 +0000 [thread overview]
Message-ID: <20131218142411.GG29247@redhat.com> (raw)
In-Reply-To: <20131211082954.GA31406@stefanha-thinkpad.muc.redhat.com>
On Wed, Dec 11, 2013 at 09:29:54AM +0100, Stefan Hajnoczi wrote:
> On Tue, Dec 10, 2013 at 10:23:41PM +0000, Alex Bennée wrote:
> >
> > stefanha@redhat.com writes:
> >
> > > On Mon, Nov 18, 2013 at 12:54:59PM +0800, Chunyan Liu wrote:
> > >> 2013/11/15 Stefan Hajnoczi <stefanha@gmail.com>
> > >>
> > >> > On Thu, Nov 14, 2013 at 04:15:28PM +0800, Chunyan Liu wrote:
> > >> > > Set NOCOW flag to newly created images to solve performance issues on
> > >> > btrfs.
> > <snip>
> > >> > This should be optional and I'm not sure it should be the default.
> > >> >
> > >> > Rationale: If you're on btrfs you probably expect the copy-on-write and
> > >> > snapshot features of the file system. We shouldn't silently disable
> > >> > that unless the user asks for it.
> > <snip>
> > >
> > > When the NOCOW attribute is set on a file, reflink copying (aka
> > > file-level snapshots) do not work:
> > >
> > > $ cp --reflink test.img test-snapshot.img
> > >
> > > This produces EINVAL.
> > >
> > > It is a regression if qemu-img create suddenly starts breaking this
> > > standard btrfs feature for existing users.
> > >
> > > Please make it a .bdrv_create() option which is off by default to avoid
> > > breaking existing users' workflows/scripts. The result should be
> > > something like:
> > >
> > > $ qemu-img create test.img 8G # file has NOCOW cleared
> > > $ qemu-img create -o nocow=on test.img 8G # file has NOCOW set
> >
> > I agree we shouldn't break existing work flows. I wonder if it would OK
> > for qemu-img to issue a warning (when not --quiet) when it detects
> > creation of an image on a partition where performance may not be as
> > expected due to COW behaviour.
>
> A warning could help or at least prompt users to consider switching to
> nocow.
IMHO such warnings are not nice - if a user does not wish to use
the 'nocow' option because they want to keep the ability to use
file label snapshots they should not be subjected to a warning
message forever more.
I suggest this is something to document in the man page instead.
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
prev parent reply other threads:[~2013-12-18 14:24 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-14 8:15 [Qemu-devel] [PATCH] qemu-img: set nocow flag to new file Chunyan Liu
2013-11-14 9:17 ` Kevin Wolf
2013-11-14 14:23 ` Alex Bligh
2013-11-14 14:28 ` Alex Bligh
2013-11-15 4:05 ` Chunyan Liu
2013-11-15 12:26 ` Kevin Wolf
2013-11-14 9:44 ` Alex Bennée
2013-11-14 10:14 ` Kevin Wolf
2013-11-15 9:38 ` Stefan Hajnoczi
2013-11-18 4:54 ` Chunyan Liu
2013-11-18 9:57 ` Stefan Hajnoczi
2013-12-10 22:23 ` Alex Bennée
2013-12-11 8:29 ` Stefan Hajnoczi
2013-12-18 14:24 ` Daniel P. Berrange [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=20131218142411.GG29247@redhat.com \
--to=berrange@redhat.com \
--cc=alex.bennee@linaro.org \
--cc=cyliu@suse.com \
--cc=kwolf@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.com \
--cc=stefanha@redhat.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 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.