From: Ian Campbell Subject: Re: [PATCH] vhd-util create: add -C|nocow option Date: Thu, 21 Nov 2013 09:39:39 +0000 Message-ID: <1385026779.6071.112.camel@kazak.uk.xensource.com> References: <1385019976-19885-1-git-send-email-cyliu@suse.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1385019976-19885-1-git-send-email-cyliu@suse.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Chunyan Liu Cc: xen-devel@lists.xensource.com, ian.jackson@eu.citrix.com List-Id: xen-devel@lists.xenproject.org On Thu, 2013-11-21 at 15:46 +0800, Chunyan Liu wrote: > Add '-C' (nocow) option to vhd-util create. > > Btrfs has terrible performance when hosting VM images, even more when the guest > in those VM are also using btrfs as file system. One way to mitigate this bad > performance is to turn off COW attributes on VM files (since having copy on > write for this kind of data is not useful). According to 'chattr' manpage, NOCOW > could be set to new or empty file only on btrfs, so add a option here so that > users could have a chance to set NOCOW to a vhd image. Is there not some btrfs (or generic) utility which could be used to do this after image creation rather than trying to build it in to every utility which creates an image file? Ian.