Driver for Linux servers running LVM.
-
class LVMISCSIDriver(*args, **kwargs)
Bases: cinder.volume.drivers.lvm.LVMVolumeDriver, cinder.volume.driver.ISCSIDriver
Executes commands relating to ISCSI volumes.
We make use of model provider properties as follows:
- provider_location
- if present, contains the iSCSI target information in the same
format as an ietadm discovery
i.e. ‘<ip>:<port>,<portal> <target IQN>’
- provider_auth
- if present, contains a space-separated triple:
‘<auth method> <auth username> <auth password>’.
CHAP is the only auth_method in use at the moment.
-
create_export(context, volume)
-
ensure_export(context, volume)
-
migrate_volume(ctxt, volume, host, thin=False, mirror_count=0)
Optimize the migration if the destination is on the same server.
If the specified host is another back-end on the same server, and
the volume is not attached, we can do the migration locally without
going through iSCSI.
-
remove_export(context, volume)
-
set_execute(execute)
-
class LVMISERDriver(*args, **kwargs)
Bases: cinder.volume.drivers.lvm.LVMISCSIDriver, cinder.volume.driver.ISERDriver
Executes commands relating to ISER volumes.
We make use of model provider properties as follows:
- provider_location
- if present, contains the iSER target information in the same
format as an ietadm discovery
i.e. ‘<ip>:<port>,<portal> <target IQN>’
- provider_auth
- if present, contains a space-separated triple:
‘<auth method> <auth username> <auth password>’.
CHAP is the only auth_method in use at the moment.
-
class LVMVolumeDriver(vg_obj=None, *args, **kwargs)
Bases: cinder.volume.driver.VolumeDriver
Executes commands relating to Volumes.
-
VERSION = '2.0.0'
-
backup_volume(context, backup, backup_service)
Create a new backup from an existing volume.
-
check_for_setup_error()
Verify that requirements are in place to use LVM driver.
-
clone_image(volume, image_location, image_id, image_meta)
-
copy_image_to_volume(context, volume, image_service, image_id)
Fetch the image from image_service and write it to the volume.
-
copy_volume_to_image(context, volume, image_service, image_meta)
Copy the volume to the specified image.
-
create_cloned_volume(volume, src_vref)
Creates a clone of the specified volume.
-
create_snapshot(snapshot)
Creates a snapshot.
-
create_volume(volume)
Creates a logical volume.
-
create_volume_from_snapshot(volume, snapshot)
Creates a volume from a snapshot.
-
delete_snapshot(snapshot)
Deletes a snapshot.
-
delete_volume(volume)
Deletes a logical volume.
-
extend_volume(volume, new_size)
Extend an existing volume’s size.
-
get_volume_stats(refresh=False)
Get volume status.
If ‘refresh’ is True, run update the stats first.
-
local_path(volume, vg=None)
-
manage_existing(volume, existing_ref)
Manages an existing LV.
Renames the LV to match the expected name for the volume.
Error checking done by manage_existing_get_size is not repeated.
-
manage_existing_get_size(volume, existing_ref)
Return size of an existing LV for manage_existing.
existing_ref is a dictionary of the form:
{‘lv_name’: <name of LV>}
-
restore_backup(context, backup, volume, backup_service)
Restore an existing backup to a new or existing volume.
-
set_execute(execute)