From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=50267 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PxvtW-0007Ww-40 for qemu-devel@nongnu.org; Fri, 11 Mar 2011 01:32:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PxvtV-0002SR-2h for qemu-devel@nongnu.org; Fri, 11 Mar 2011 01:32:13 -0500 Received: from mx1.redhat.com ([209.132.183.28]:16129) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PxvtU-0002RQ-P5 for qemu-devel@nongnu.org; Fri, 11 Mar 2011 01:32:13 -0500 Message-ID: <4D79C1D7.1030105@redhat.com> Date: Fri, 11 Mar 2011 07:31:51 +0100 From: Jes Sorensen MIME-Version: 1.0 Subject: Re: [Qemu-devel] Issue with snapshot outside qcow2 disk - qemu 0.14.0 References: <4D78A0E8.7000606@redhat.com> <102956.23165.qm@web161602.mail.bf1.yahoo.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: SAURAV LAHIRI , qemu-devel@nongnu.org On 03/10/11 22:04, Stefan Hajnoczi wrote: > On Thu, Mar 10, 2011 at 7:57 PM, SAURAV LAHIRI wrote: >> The high level use case is that of being able to backup user specified disks of a VM without having to bring down the VM. > > Excellent, that sounds exactly like Jes is addressing so future > QEMU/KVM releases will hopefully have the live snapshot/merge > capability. > >> snapshot_blkdev: Regarding this I do have a couple of questions. >> >> 1. If the snapshot cannot be merged then it could mean that there are several snapshot files. One readonly for each of the previous snapshots and the last one being the active one, which handles all the current writes. Post backup If do have to restore to a particular snapshot then i would probably have to copy all the files in the chain and maintain the entire chain. But would it not affect read performance if several snapshot files are maintained, particularly if the VM is hosting a database like mysql ? Could you please clarify. > > If the VM is not running you can use the qemu-img commit command to > merge the snapshot back down into the base image. After that you only > have one image file again and can restart the VM. Hopefully the > deltas are small enough that this process is quick. > > In the future a live merge command will take care of this and avoid > the downtime. Yep, qemu-img convert should be able to copy it into a single image so you can delete the chain. Cheers, Jes