Re: backup domU

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mathieu Kretchner wrote:

Do you have good how to about backup a LV ? and creating a domU in an LV ?



Google for "LVM2 snapshot" or look at the "snapshot" option on the man
page for "lvcreate" to answer the first half of your question.

Here is a snippet of the cron script that I run twice a day to backup
all of my guests while they are running.

/usr/sbin/lvcreate --extents 100%FREE --snapshot --name vmsnapshots /dev/vms/vms
/bin/mount /dev/vms/vmsnapshots /vmsnapshots
DAY="`date +%A-%H%M`"
/usr/bin/time --format "%E" /bin/tar --sparse -zcvf /mnt/ssbackup01/vms-$DAY.tar.gz /var/lib/xend/domains /vmsnapshots
/bin/umount /vmsnapshots
/usr/sbin/lvremove --force /dev/vms/vmsnapshots

I am also interested in seeing a detailed howto for the "creating a domU
in an LV" part of your question.  I currently do live backups of all of
my virtual machines using LVM2 snapshots but I had to put my virtual
machine images in files instead of partitions to accomplish this.  I
never successfully created a virtual machine in an a logical volume
partition.  Some people say that I am sacrificing performance by putting
my virtual machines in files.  If that is true, then I'd love to see a
detailed example of creating an arbitrary Xen guest image in a a logical
volume.

--
Good luck,
Aaron Metzger


--
Fedora-xen mailing list
Fedora-xen@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-xen

[Index of Archives]     [Fedora General]     [Fedora Music]     [Linux Kernel]     [Fedora Desktop]     [Fedora Directory]     [PAM]     [Big List of Linux Books]     [Gimp]     [Yosemite News]

  Powered by Linux