Received: from eggs.gnu.org ([140.186.70.92]:51181) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RNQjP-0001IZ-IO for qemu-devel@nongnu.org; Mon, 07 Nov 2011 10:03:36 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RNQjO-0002b6-Fu for qemu-devel@nongnu.org; Mon, 07 Nov 2011 10:03:27 -0500 Received: from mx1.redhat.com ([209.132.183.28]:43640) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RNQjO-0002az-7i for qemu-devel@nongnu.org; Mon, 07 Nov 2011 10:03:26 -0500 From: Markus Armbruster References: <4EB78CE9.4030305@linux.vnet.ibm.com> Date: Mon, 07 Nov 2011 16:03:05 +0100 In-Reply-To: <4EB78CE9.4030305@linux.vnet.ibm.com> (Zhi Hui Li's message of "Mon, 07 Nov 2011 15:46:49 +0800") Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] backing_file Path List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Zhi Hui Li Cc: kwolf@redhat.com, zhihuili@cn.ibm.com, Stefan Hajnoczi cowcoww , QEMU-devel Zhi Hui Li writes: > when I trace the code of qemu-img.c=EF=BC=8C I found in the image file, t= he > backing_file use the relative path, I think Maybe it has some > problems. > > for example: > > 1: qemu-img create -o backing_file=3D../xxxx aa.img 5G > > 2: qemu-system-x86_64 aa.img > > if you change aa.img's the path, the exec is wrong,it can't find the > backing_file path, because the backing_file use the relative path, > Could we change the relative path to the absolute path? qemu-img stores exactly the path the user asks it to store. That's a feature. It lets the user can pick what kinds of moves break his COW: 1. COW refers to its backing image with a relative path. Moving both together works. Moving just one of them breaks. 2. COW refers to its backing image with an absolute path. Moving just the COW works. Anything else breaks.