----- Original Message ----- > From: "Paolo Bonzini" <pbonz...@redhat.com> > To: qemu-devel@nongnu.org > Sent: Tuesday, February 28, 2012 7:02:40 PM > Subject: Re: [Qemu-devel] Live Block Migration using Mirroring > > Il 28/02/2012 18:46, Federico Simoncelli ha scritto: > > > > Thank you for getting this. Being able to have a bogus backing > > > > file > > > > was a bonus but it's not really required for the mirrored live > > > > block > > > > migration. We can add the support for switching the backing > > > > file in the > > > > drive-reopen part. > > > > > > Wait, it's not really required for oVirt because it creates the > > > snapshot outside QEMU. What about everyone else? > > > > They'll have (as oVirt) two mirrored snapshot pointing at the same > > base. The only difference is that the image is created internally, > > but > > that's not hard. > > Can you detail how you are switching the backing file in the > drive-reopen? Either the BlockDriverState opened by blkmirror, or > the > one opened at the end, will have to use the "wrong" backing_file. > How > do you arrange for that?
Step 1 - Initital Scenario ========================== VM1 is running on the src/hd0base. [src/hd0base] <= VM1(read-write) Step 3 - Mirrored Live Snapshot =============================== A mirrored live snapshot is issued using src/hd0snap1 and dst/hd0snap1 as image files (both having src/hd0base as backing file). [src/hd0base] <- [src/hd0snap1] <= VM1(read-write) ^-- [dst/hd0snap1] <= VM1(read-write) Step 4 - Backing File Copy ========================== An external manager copies src/hd0base to the destination (dst/hd0base). [src/hd0base] <- [src/hd0snap1] <= VM1(read-write) [dst/hd0base]^-- [dst/hd0snap1] <= VM1(read-write) Step 5 - Final Switch to Destination ==================================== VM1 is now able to switch to the destination for both read and write operations fixing the backing file path in dst/hd0snap1. [src/hd0base] <- [src/hd0snap1] [dst/hd0base] <- [dst/hd0snap1] <= VM1(read-write) -- Federico