[Systems] How to migrate kvm guests in LVM volumes

Bernie Innocenti bernie at codewiz.org
Wed Dec 9 13:12:45 EST 2009


(untested procedure)

First, shutdown the VM, then do:

 mount /dev/treehouse/beamrider-root /mnt
 ssh housetree mount /dev/housetree/beamrider-root /mnt
 rsync -PHAXphax --delete --numeric-ids /mnt/ housetree:/mnt/
 rsync -a /etc/libvirt/qemu/beamrider.xml housetree:/etc/libvirt/qemu/
 umount /mnt
 ssh housetree umount /mnt

Then you log to housetree and create the domain in virsh.

You can reduce downtime to just a few minutes by doing a first rsync
iteration from within the VM while it's still running. Make sure you
pass all the fancy switches to rsync or you'll loose information on the
copy.

-- 
   // Bernie Innocenti - http://codewiz.org/
 \X/  Sugar Labs       - http://sugarlabs.org/



More information about the Systems mailing list