WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] Xen, LVM and snapshots

To: "Morten W. Petersen" <morten@xxxxxxxxxxxxxx>
Subject: Re: [Xen-users] Xen, LVM and snapshots
From: Mike Lovell <mike@xxxxxxxxxxxx>
Date: Thu, 16 Oct 2008 16:29:03 -0600
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Thu, 16 Oct 2008 15:29:41 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <48F4D377.1060503@xxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <48F4D377.1060503@xxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.17 (X11/20080922)
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

<Prev in Thread] Current Thread [Next in Thread>