xen-users
Re: [Xen-users] Xen, LVM and snapshots
Morten W. Petersen wrote:
> We're considering using snapshots of LVM logical volumes as a backup
> feature, that is, having domU instances running on each of their own
> logical volume, and then in the dom0, create snapshots and take backups.
>
> Has anyone else tried this? Is it safe?
>
> I saw an old message from 2006 on this list, where it is said that
> "Common understanding is that LVM2 snapshots are unstable".
>
> Is that still the case?
I do something similar to this with a xen guest that I have. I currently
have openSuSE 10.3 running as dom0. I have a linux guest that is running
paravirtualized and is using an LVM volume as it filesystem. I have a
script that I run in dom0 that creates a LVM snapshot of the guest
volume, mounts the snapshot as read only, creates a tarball of the guest
root filesystem, unmounts the snapshot, and then removes the lvm
snapshot. So far this has worked great for backing up the root
filesystem for my xen guest. I haven't needed to try a restore yet
(thankfully things haven't died). Also, this hasn't been tested under
heavy load so I make no guarantees about performance.
What I did for my set up is an adaptation of a tutorial on
howtoforge.com (http://howtoforge.com/linux_lvm_snapshots). From my
understanding, if you create an LVM snapshot, that snapshot stays
consistent independent of what is happening on the non-snapshot volume.
It has been a while since I tested that fact but I'm pretty sure it
worked that way. So you should be able to do what you are asking about.
If you would like a copy of the script that i use, i can clean it up and
send it to you.
Mike
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
|
|
|