From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55429) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aYYUt-0005x5-A8 for qemu-devel@nongnu.org; Wed, 24 Feb 2016 07:24:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aYYUs-0005Nq-1l for qemu-devel@nongnu.org; Wed, 24 Feb 2016 07:24:51 -0500 Date: Wed, 24 Feb 2016 07:24:43 -0500 From: Jeff Cody Message-ID: <20160224122443.GC23671@localhost.localdomain> References: <951bf8f8c49ff3c2a38dcd02fe78ae00a5de8add.1456274059.git.jcody@redhat.com> <20160224101937.GC4485@noname.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160224101937.GC4485@noname.redhat.com> Subject: Re: [Qemu-devel] [PATCH 3/4] block/vpc: give option to force the current_size field in .bdrv_create List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: pl@kamp.de, qemu-devel@nongnu.org, qemu-block@nongnu.org On Wed, Feb 24, 2016 at 11:19:37AM +0100, Kevin Wolf wrote: > Am 24.02.2016 um 01:47 hat Jeff Cody geschrieben: > > When QEMU creates a VHD image, it goes by the original spec, > > calculating the current_size based on the nearest CHS geometry (with an > > exception for disks > 127GB). > > > > Apparently, Azure will only allow images that are sized to the nearest > > MB, and the current_size as calculated from CHS cannot guarantee that. > > > > Allow QEMU to create images similar to how Hyper-V creates images, by > > setting current_size to the specified virtual disk size. This > > introduces an option, force_size, to be passed to the vpc format during > > image creation, e.g.: > > > > qemu-img convert -f raw -o force_size -O vpc test.img test.vhd > > > > Bug reference: https://bugs.launchpad.net/qemu/+bug/1490611 > > > > Signed-off-by: Jeff Cody > > We need to set a different creator string here that makes vpc_open() > recognise the image as current_size based. > > Kevin How about "qem2"? I initially thought about just changing the case on "qemu", but I was afraid some other software may treat the app creator string as case-insensitive. I'll also update patch 1, to recognize that string as well.