[CentOS-virt] Backing up a running KVM guest
maillists at conactive.com
Fri Mar 27 14:31:40 UTC 2009
Julian Price wrote on Thu, 26 Mar 2009 16:48:36 +0000:
> Are you syncing the disk image as one file via the host, or all the
> files within via the guest?
The sync happens as if I had two physical machines. Phys <backup> logs in
to Virt <tobebackupped> on Phys <wherever> and syncs Virt <tobebackupped>
to the local storage (be that image, LVM partition or what).
I use it to backup to a backup mirror that can take over if the original
fails. The complete sync usually takes only a few minutes per VM.
(I *could* add a sql flush and lock on the remote side in the custom
script that is triggered by the ssh rsync login, but I would need to hold
it for longer (during the complete database file sync) as creating a
snapshot, of course.)
> If you are just syncing files in the guest (which I wouldn't protest
> about) then the methods are not really comparable because the essential
> point of my approach is that the whole bootable image is backed up,
> which is desirable to some people for lots of reasons.
I'm not sure what you mean. I have two identical and working "images"
after the sync (actually it's two LVM partitions). If I were using images
I had two images after that. It's independant of the storage method for
your LVM and you can use different storage on both sides. But is has to be
created and formatted before you can use it for backup. For your method I
think you just need to create the LVM partition (as large or larger than
the source), no formatting. It's also possible that my method doesn't work
for HVM guests where you may need a bootloader, I'm using only PV CentOS 5
and 4 guests.
Kai Schätzl, Berlin, Germany
Get your web at Conactive Internet Services: http://www.conactive.com
More information about the CentOS-virt