Backlog #1341

shared LVM driver

Added by SZTAKI ITAK almost 9 years ago. Updated over 7 years ago.

Status:ClosedStart date:07/09/2012
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Drivers - Storage
Target version:-

Description

Hi,

We have developed at MTA SZTAKI Internet Technology Dept. (ITAK) a new datastore and transfer manager driver. It uses a shared block device, which could be iSCSI (also should work with certain AoE, Fibre Channel setups) etc but it must be accessible for rw on all nodes and frontends. There is a volume group on the block device, and the VM images are logical volumes, similar to the iSCSI driver, but it doesn't depend on tgtadm, it works with out-of-the-box iSCSI (or AoE) storages as well.
If you find it useful, feel free to use the code...

Some limitations:
  • If there is more than one frontend, the administrator should do something to avoid concurrent LVM metadata writes (e.g CLVM, lockfile on a shared space, etc)
  • It doesn't support live migration, except if you use CLVM (and shared system driver of course), because the LV-s used by the VM arent active on the target node (with CLVM this is not an issue) - a hook before MIGRATE would be helpful in this situation (we are planning to send a patch to create MIGRATE hook).
  • The administrator needs to make sure that the block device is available on all nodes and frontends, and make sure that the volume group shows up everywhere with same name as in shared_lvm.conf
  • After you apply the attached patch, you should run the attached permissions script as well. It applies the necessary file permissions on the new driver scripts.

shared_lvm.patch Magnifier (37.6 KB) SZTAKI ITAK, 07/09/2012 10:05 AM

permissions_sh_lvm.sh Magnifier (156 Bytes) SZTAKI ITAK, 07/09/2012 10:05 AM

shared_lvm.patch Magnifier (37.6 KB) SZTAKI ITAK, 07/23/2012 09:50 AM


Related issues

Duplicated by Feature #1809: remove the CLVM dependency by operating directly in the p... Closed 03/12/2013

History

#1 Updated by SZTAKI ITAK almost 9 years ago

New patch, with some bugfixes...

#2 Updated by Ruben S. Montero about 8 years ago

  • Tracker changed from Request to Feature
  • Category set to Drivers - Storage

#3 Updated by Ruben S. Montero about 8 years ago

  • Target version set to Release 4.2

#4 Updated by SZTAKI ITAK about 8 years ago

Hi,

I recently rewrote the LVM transfer manager according to this thread: http://lists.opennebula.org/pipermail/users-opennebula.org/2013-March/022305.html

You can download it from here: https://dl.dropboxusercontent.com/u/140123/lvm.tar.gz

Some comments:
- In case of Ubuntu >=12.10, the lvchange an command doesn't work ( https://bugs.launchpad.net/ubuntu/+source/lvm2/+bug/1088081 ). A possible solution is changing the /lib/udev/rules.d/85-lvm2.rules file, and removing the "/sbin/lvm vgchange -a y" command.
Because of disk caching, I need to execute a "sync;echo 3 > /proc/sys/vm/drop_caches" in the tm scripts, forcing the nodes to re-read the content of the partition. If anyone knows a better solution to this, please let me know.
- Live migration isn't working without CLVM, but here is a workaround (pre/postmigrate scripts for the shared system ds driver, and for the lvm tm driver): https://dl.dropboxusercontent.com/u/140123/livemigrate.tar.gz
- Although I tested the code, it might contain bugs, so it is not recommended for production.

#5 Updated by Ruben S. Montero almost 8 years ago

  • Target version changed from Release 4.2 to Release 4.4

#6 Updated by Ruben S. Montero almost 8 years ago

  • Tracker changed from Feature to Backlog
  • Target version deleted (Release 4.4)

#7 Updated by Ruben S. Montero over 7 years ago

  • Status changed from New to Pending

#8 Updated by Ruben S. Montero over 7 years ago

  • Status changed from Pending to Closed

There is a new add-on for this.

Also available in: Atom PDF