From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=41273 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PVb0y-0003zq-NO for qemu-devel@nongnu.org; Wed, 22 Dec 2010 21:34:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PVb0x-0007IC-NB for qemu-devel@nongnu.org; Wed, 22 Dec 2010 21:34:48 -0500 Received: from mail-ww0-f53.google.com ([74.125.82.53]:39395) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PVb0x-0007I8-FP for qemu-devel@nongnu.org; Wed, 22 Dec 2010 21:34:47 -0500 Received: by wwi18 with SMTP id 18so5622948wwi.10 for ; Wed, 22 Dec 2010 18:34:46 -0800 (PST) MIME-Version: 1.0 In-Reply-To: References: Date: Thu, 23 Dec 2010 02:34:46 +0000 Message-ID: Subject: Re: [Qemu-devel] Asynchronously Mirroring a Virtual Machine From: Stefan Hajnoczi Content-Type: text/plain; charset=ISO-8859-1 List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Tomer Margalit Cc: scipioenterprises@yahoo.com, "Zaidenberg, Nezer" , qemu-devel@nongnu.org, Nezer Zaidenberg , Yoshiaki Tamura On Wed, Dec 22, 2010 at 12:43 PM, Tomer Margalit wrote: > What I would like to add to it is the ability to asynchronously mirror a > (QEMU) VM as well, so that if the primary site crashes, the VM can be > restored (to the last stable point) immediately. > Since I want it to be as general as possible, I will not rely on my mirror, > but only on there being a virtual block device that is mirroring me (and > that has consistent writes (that is, if write A succeeded, and afterwards > write B succeeded, then if B is on the secondary site, then A must be there > too)), and that there is some kind of marking mechanism (so that I can mark > the last consistent state). > The reason I want to do this using QEMU is that it has live migration - > which is almost what I need. > Right now my plan is to treat the memory as a file, and put it and all the > vm images on the same mirroring block device. Have you looked at Kemari for KVM (try searching qemu-devel)? It builds a fault tolerance mechanism on top of live migration. Memory, disk, and network changes are sent to a secondary machine which passively tracks the state of the VM. You can fail over to the last completed transaction state. Sounds similar to what you want to do. Stefan