From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takuya Yoshikawa Subject: Re: disk image snapshot functionality Date: Wed, 29 Sep 2010 15:07:23 +0900 Message-ID: <4CA2D79B.5010407@oss.ntt.co.jp> References: <0CDD4EAF-97E9-4718-A106-2634D891C5CF@hkl.hms.harvard.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org To: Peter Doherty Return-path: Received: from serv2.oss.ntt.co.jp ([222.151.198.100]:38956 "EHLO serv2.oss.ntt.co.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750801Ab0I2GGD (ORCPT ); Wed, 29 Sep 2010 02:06:03 -0400 In-Reply-To: <0CDD4EAF-97E9-4718-A106-2634D891C5CF@hkl.hms.harvard.edu> Sender: kvm-owner@vger.kernel.org List-ID: Hi, (2010/09/29 5:24), Peter Doherty wrote: > Hi, > > I'm using Centos5.5 on the host, and the KVM that's available in the repos. I'm using linux VMs too. My disk images are qcow2 files. > Here's what I want: > To be able to, on the host, create a snapshot of the guest's disk image, without shutting down the guest, so that I can then restore back to a point in time for the guest. Yesterday, I heard a similar desire at the Virtualization End User Discussion @ LinuxCon Japan. What you want to do is: - taking the whole VM disk image snapshot or - just taking specific partition's image? Generally speaking, taking the whole VM disk image snapshot without breaking guest side consistency seems difficult. Even though you restrict to a specific partition, you need to guarantee that the file system is in an appropriate state. Anybody has better ideas? Takuya > I thought I could do this with the qcow2 images. > I've used: > qemu-img snapshot -c snapname disk_image.qcow2 > to create the snapshot. > > It doesn't work. The snapshots claim to be created, but if I shut down the guest, apply the snapshot > ( qemu-img snapshot -a snapname disk_image.qcow2 ) > the guest either: > a.) no longer boots (No bootable disk found) > b.) boots, but is just how it was when I shut it down (it hasn't reverted back to what it was like when the snapshot was made) > > > It makes no sense. I can sometimes apply the first snapshot, and it has worked...but subsequent snapshots are a no go. > One thing that is suspicious is that the VM SIZE and CLOCK are zero: > # qemu-img snapshot -l test1.qcow2 > Snapshot list: > ID TAG VM SIZE DATE VM CLOCK > 1 with100mb 0 2010-09-28 11:48:23 00:00:00.000 > 2 with200mb 0 2010-09-28 11:50:53 00:00:00.000 > 3 with300mb 0 2010-09-28 11:52:49 00:00:00.000 > 4 whenoff 0 2010-09-28 11:56:41 00:00:00.000 > > > # /usr/libexec/qemu-kvm --help > QEMU PC emulator version 0.9.1 (kvm-83-maint-snapshot-20090205), Copyright (c) 2003-2008 Fabrice Bellard > > > I can't find much info about using qcow2 images when I search. Any help would be appreciated. > > Thanks. > > Peter > -- > To unsubscribe from this list: send the line "unsubscribe kvm" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html