From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:34002) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RJL2z-0007AL-GD for qemu-devel@nongnu.org; Thu, 27 Oct 2011 04:10:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RJL2y-0007w2-Eg for qemu-devel@nongnu.org; Thu, 27 Oct 2011 04:10:45 -0400 Received: from mail-ey0-f173.google.com ([209.85.215.173]:39922) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RJL2y-0007ua-5P for qemu-devel@nongnu.org; Thu, 27 Oct 2011 04:10:44 -0400 Received: by mail-ey0-f173.google.com with SMTP id 6so2486272eyh.4 for ; Thu, 27 Oct 2011 01:10:43 -0700 (PDT) Date: Thu, 27 Oct 2011 08:29:07 +0100 From: Stefan Hajnoczi Message-ID: <20111027072907.GD32287@stefanha-thinkpad.localdomain> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] Correct syntax for named snapshots List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Ottavio Cc: qemu-devel@nongnu.org On Wed, Oct 26, 2011 at 05:24:01PM +0100, Ottavio wrote: > According to the latest doc file you create a named snapshot like this: > > qemu-img snapshot [-l | -a snapshot | -c snapshot | -d snapshot] base-image.img > > Is this other following syntax still supported or deprecated: > > "qemu-img create -f qcow2 -b base-image.img snapshot.img" ? > > The latter is on the qemu wiki but not on the qemu-doc.html file. > > Can you cc: me please? Thanks These two commands do different things. There are two different snapshot concepts: internal and external snapshot. Internal snapshots can be created with qcow2 and can be manipulated with the qemu-img snapshot command. They are called "internal" because all snapshot data is part of the same image file; you can have a single qcow2 file that contains 10 different snapshots. External snapshots can be created with any format that supports backing files (qcow2, qed, vmdk, ...) and is created with qemu-img create -o backing_file=base-image.img -f qcow2 vm001.qcow2 (or with the older -b option). They are called "external" snapshots because they involve multiple files and data is stored separately. In the command-line I gave you could access base-image.img in read-only fashion - the base image is the "snapshot" and the vm001.qcow2 image file contains data written since creating the new image file. The word "snapshot" is overloaded in QEMU, we use it for several different things, but I hope this explanation helps. Stefan