What is the best/recomended/official way to backup VMs

Mat mat at olitec.ca
Thu Aug 13 19:33:29 UTC 2009


Jarl Friis wrote:
> It is not the best way, it is error-prone, a live guest system
> consists of more than what is found on the virtual disk. As Etienne
> Goyer mentioned this approach will most likely fail (to recover) when
> guests contains running databases.
> 
> Expecting LVM snapshots to be sufficient for making a backup of a
> running guest is like expecting powering of the machine (the hard way)
> will not rsult in data-loss. Because in both situations, data on disk
> is all what you have. You will lose disk-writes that has not been
> synced yet, and of course the machine state (which may be less important)

I'm not sure why that didn't cross my mind before, bringing the VM 
backup from the LVM snapshot is like bringing computer back up from a 
power outage. Not good.

Just an idea: what if both a KVM snapshot and the LVM snapshot could be 
done at the same time? It should then be possible to bring the VM up in 
a running state. The process would have to be connected and not done 
with two separate tools, I don't know of anything that can do this now. 
Lost disk-writes would still have to be considered on the guest though.

My idea is probably trying to address the underlining issue from the 
wrong angle. I suppose that if I needed a service to run 24/7 and 
downtime was not acceptable, I would run my services in a server farm 
with proper fault-tolerance and redundancy, and where database backup 
and recoveries wouldn't be done on the VM level.

MatOC




More information about the ubuntu-server mailing list