Best method for backup in local hard disk

maykel535

Active Member
Mar 26, 2012
52
0
26
Hi, I have installed proxmox 3.1 . It worked with proxmox from version 1.9 and I love this software + openvz + kvm jeje.

I have a question, I would like to backup virtual machines on an additional disk that I added to the server locally and wanted to know if it is better to format it as ext4 and mount it and add it as a directory in the storage section Proxmox, or according to this documentation , add or create a lvm volume group and backup in? That way is more effective and why??

That is, it is faster to save backup a mounted hard drive without lvm or lvm mounted hard disk as in the documentation of down here?

Thanks in advanced.



[h=3]LVM Groups with Local Backing[/h]In this configuration, physical block devices (which can be DRBD devices) are used as the physical volumes for LVM logical volume storage. Before you can store VM´s this way, you first need to configure LVM2 using the console. Full management is not possible through the web interface at this time
This is a three step procedure (I just plugged in a 8 GB USB Stick for demonstration, recognized as /dev/sdb on my box)

  1. Physically install all devices you wish to import into a volume group
  2. Define those physical devices as LVM physical volumes (storage that can be used by LVM volume groups.
First create the physical volume (pv):
proxmox-ve:~# pvcreate /dev/sdb1
Physical volume "/dev/sdb1" successfully created
proxmox-ve:~#Second, create a volume group (vg):
proxmox-ve:~# vgcreate usb-stick /dev/sdb1
Volume group "usb-stick" successfully created
proxmox-ve:~#And finally: Add the LVM Group to the storage list via the web interface:

"Storage name: usb", "Base storage: Existing volume groups", "Volume Group Name: usb-stick"
Now you can create the KVM VM:
Type: Fully virtualized (KVM)
Disk storage: usb (lvm)
Disk space (GB): 1
Image format: raw (that is the only option you can choose now and therefore does not support Live_Snapshots)

After the creation (let's put will be VM 117), you will have an additional logical volume of the size of the VM's disk space:
proxmox-ve:~# lvdisplay
--- Logical volume ---
LV Name /dev/usb-stick/vm-117-disk-1
VG Name usb-stick
LV Size 1.00 GB
Note: after the experiment, to remove the test storage do:

Remove usb storage from web interface
then

proxmox-ve:~# vgremove usb-stick
Volume group "usb-stick" successfully removedthen
proxmox-ve:~# pvremove /dev/sdb1
Labels on physical volume "/dev/sdb1" successfully wiped
 
Just format the second disk (e.g. as ext3/ext4/xfs) and mount the second disk via fstab somewhere, then add this as directory storage for backup.
 
  • Like
Reactions: Tonmoy

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!