def rm_func(vios_w): LOG.info("Removing SSP disk connection to VIOS %(vios)s.", {'vios': vios_w.name}, instance=instance) return tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func)
def detach_disk(self, instance): """Detaches the storage adapters from the image disk. :param instance: Instance to disconnect the image for. :return: A list of all the backing storage elements that were disconnected from the I/O Server and VM. """ lpar_uuid = vm.get_pvm_uuid(instance) # Build the match function match_func = tsk_map.gen_match_func(pvm_stg.VDisk) vios_w = pvm_vios.VIOS.get(self._adapter, uuid=self._vios_uuid, xag=[pvm_const.XAG.VIO_SMAP]) # Remove the mappings. mappings = tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func) # Update the VIOS with the removed mappings. vios_w.update() return [x.backing_storage for x in mappings]
def rm_func(vios_w): LOG.info( _LI("Disconnecting instance %(inst)s from storage disks.") % {'inst': instance.name}) return tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func)
def rm_func(vios_w): LOG.info("Removing vSCSI mapping from physical volume %(dev)s " "on vios %(vios)s", {'dev': device_name, 'vios': vios_w.name}, instance=self.instance) removed_maps = tsk_map.remove_maps( vios_w, vm_uuid, tsk_map.gen_match_func(pvm_stor.PV, names=[device_name])) return removed_maps
def rm_func(vios_w): LOG.info(_LI("Removing vSCSI mapping from Physical Volume %(dev)s " "to VM %(vm)s") % {'dev': device_name, 'vm': vm_uuid}) removed_maps = tsk_map.remove_maps( vios_w, vm_uuid, tsk_map.gen_match_func(pvm_stor.PV, names=[device_name])) for rm_map in removed_maps: slot_mgr.drop_vscsi_mapping(rm_map) return removed_maps
def rm_func(vios_w): LOG.info("Removing vSCSI mapping from physical volume %(dev)s.", {'dev': device_name}, instance=self.instance) removed_maps = tsk_map.remove_maps( vios_w, vm_uuid, tsk_map.gen_match_func(pvm_stor.PV, names=[device_name])) for rm_map in removed_maps: slot_mgr.drop_vscsi_mapping(rm_map) return removed_maps
def rm_func(vios_w): LOG.info( _LI("Removing SSP disk connection between VM %(vm)s and " "VIOS %(vios)s."), { 'vm': instance.name, 'vios': vios_w.name }) return tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func)
def rm_func(vios_w): LOG.info( _LI("Removing vSCSI mapping from Physical Volume %(dev)s " "to VM %(vm)s") % { 'dev': device_name, 'vm': vm_uuid }) return tsk_map.remove_maps( vios_w, vm_uuid, tsk_map.gen_match_func(pvm_stor.PV, names=[device_name]))
def rm_func(vios_w): # If the vios doesn't match, just return if vios_w.uuid != vios_uuid: return None LOG.info(_LI("Disconnecting instance %(inst)s from storage " "disks."), {'inst': self.instance.name}, instance=self.instance) return tsk_map.remove_maps(vios_w, self.vm_uuid, match_func=match_func)
def rm_func(vios_w): # If the vios doesn't match, just return if vios_w.uuid not in self.vios_uuids: return None LOG.info("Disconnecting storage disks.", instance=self.instance) removed_maps = tsk_map.remove_maps(vios_w, self.vm_uuid, match_func=match_func) for rm_map in removed_maps: slot_mgr.drop_vscsi_mapping(rm_map) return removed_maps
def rm_func(vios_w): LOG.info( _LI("Removing vSCSI mapping from Physical Volume %(dev)s " "to VM %(vm)s"), { 'dev': device_name, 'vm': vm_uuid }) removed_maps = tsk_map.remove_maps( vios_w, vm_uuid, tsk_map.gen_match_func(pvm_stor.PV, names=[device_name])) for rm_map in removed_maps: slot_mgr.drop_vscsi_mapping(rm_map) return removed_maps
def detach_disk(self, instance): """Detaches the storage adapters from the image disk. :param instance: Instance to disconnect the image for. :return: A list of all the backing storage elements that were disconnected from the I/O Server and VM. """ lpar_uuid = vm.get_pvm_uuid(instance) # Build the match function match_func = tsk_map.gen_match_func(pvm_stg.VDisk) vios_w = pvm_vios.VIOS.get( self._adapter, uuid=self._vios_uuid, xag=[pvm_const.XAG.VIO_SMAP]) # Remove the mappings. mappings = tsk_map.remove_maps( vios_w, lpar_uuid, match_func=match_func) # Update the VIOS with the removed mappings. vios_w.update() return [x.backing_storage for x in mappings]
def rm_func(vios_w): LOG.info("Disconnecting instance from storage disks.", instance=instance) return tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func)
def rm_func(vios_w): LOG.info(_LI("Disconnecting instance %(inst)s from storage disks.") % {'inst': instance.name}) return tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func)
def rm_func(vwrap): LOG.info("Removing SSP disk connection to VIOS %s.", vwrap.name, instance=instance) return tsk_map.remove_maps(vwrap, lpar_uuid, match_func=match_func)
def rm_vopt_mapping(vios_w): return tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func)
def rm_func(vios_w): LOG.info(_LI("Removing SSP disk connection between VM %(vm)s and " "VIOS %(vios)s."), {'vm': instance.name, 'vios': vios_w.name}) return tsk_map.remove_maps(vios_w, lpar_uuid, match_func=match_func)
def rm_func(vios_w): LOG.info( _LI("Removing vSCSI mapping from Physical Volume %(dev)s " "to VM %(vm)s") % {"dev": device_name, "vm": vm_uuid} ) return tsk_map.remove_maps(vios_w, vm_uuid, tsk_map.gen_match_func(pvm_stor.PV, names=[device_name]))