The cinder.volume.drivers.emc.vnx.client Module

class Client(ip, username, password, scope, naviseccli, sec_file)

Bases: object

add_image(mirror_name, sp_ip, secondary_lun_id)
add_lun_to_sg(storage_group, lun, max_retries)

Adds the lun to storage_group.

attach_snapshot(smp_name, snap_name)
cleanup_migration(src_id, dst_id)

Invoke when migration meets error.

Parameters:
  • src_id – source LUN id
  • dst_id – destination LUN id
copy_snapshot(snap_name, new_snap_name)
create_cg_snapshot(cg_snap_name, cg_name)
create_consistency_group(cg_name, lun_id_list=None)
create_lun(pool, name, size, provision, tier, cg_id=None, ignore_thresholds=False)
create_mirror(mirror_name, primary_lun_id)
create_mount_point(lun_name, smp_name)
create_snapshot(lun_id, snap_name)

Creates a snapshot.

create_storage_group(name)
delete_cg_snapshot(cg_snap_name)
delete_consistency_group(cg_name)
delete_lun(name, force=False)

Deletes a LUN or mount point.

delete_mirror(mirror_name)
delete_snapshot(snapshot_name)

Deletes a snapshot.

deregister_initiators(initiators)
detach_snapshot(smp_name)
enable_compression(lun)

Enables compression on lun.

Parameters:lun – instance of VNXLun
expand_lun(*args, **kwargs)
fracture_image(mirror_name)
get_available_ip()
get_cg(name)
get_enablers()
get_fc_targets(sp=None, port_id=None)
get_iscsi_targets(sp=None, port_id=None, vport_id=None)
get_lun(name=None, lun_id=None)
get_lun_id(volume)

Retrieves the LUN ID of volume.

get_mirror(mirror_name)
get_pool(name)
get_pool_feature()
get_pool_name(lun_name)
get_pools()
get_serial()
get_storage_group(name)
get_vnx_enabler_status()
get_wwn_of_online_fc_ports(ports)

Returns wwns of online fc ports.

wwn of a certain port will not be included in the return list when it is not present or down.

is_compression_enabled()
is_dedup_enabled()
is_fast_cache_enabled()
is_fast_enabled()
is_mirror_view_enabled()
is_snap_enabled()
is_thin_enabled()
lun_has_snapshot(lun)

Checks lun has snapshot.

Parameters:lun – instance of VNXLun
migrate_lun(*args, **kwargs)
modify_lun()
modify_snapshot(snap_name, allow_rw=None, auto_delete=None)
ping_node(port, ip_address)
promote_image(mirror_name)
register_initiator(storage_group, host, initiator_port_map)

Registers the initiators of host to the storage_group.

Parameters:
  • storage_group – the storage group object.
  • host – the ip and name information of the initiator.
  • initiator_port_map – the dict specifying which initiators are bound to which ports.
remove_image(mirror_name)
session_finished(src_lun)
sg_has_lun_attached(sg)
sync_image(mirror_name)
update_consistencygroup(cg, lun_ids_to_add, lun_ids_to_remove)
verify_migration(src_id, dst_id, dst_wwn)

Verify whether migration session finished successfully.

Parameters:
  • src_id – source LUN id
  • dst_id – destination LUN id
  • dst_wwn – destination LUN WWN
Returns Boolean:
 

True or False

class Condition

Bases: object

Defines some condition checker which are used in wait_until, .etc.

static is_lun_expanded(lun, new_size)
static is_lun_io_ready(lun)
static is_lun_ops_ready(lun)
static is_mirror_synced(mirror)
static is_object_existed(vnx_obj)