mkvdiskhostmap should use the force flag with multihostmap
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Fix Released
|
Medium
|
Gerald McBrearty |
Bug Description
The mkvdiskhostmap method is inefficient for volumes that will be mapped to multiple host entries on the back-end
When multihostmap is true is calls off to the svc sees if it fails and only then add the '-force' option
def mkvdiskhostmap(
"""Map vdisk to host.
If vdisk already mapped and multihostmap is True, use the force flag.
"""
ssh_cmd = ['svctask', 'mkvdiskhostmap', '-host', '"%s"' % host,
out, err = self._ssh(ssh_cmd, check_exit_
if 'successfully created' in out:
return
if not err:
msg = (_('Did not find success message nor error for %(fun)s: '
raise exception.
if err.startswith(
if not multihostmap:
msg = 'CMMVC6071E The VDisk-to-host mapping '\
return self.run_
If the -force is added if multihostmap we don't call out of ssh to the back-end svc twice to complete the operation
def mkvdiskhostmap(
"""Map vdisk to host.
If vdisk already mapped and multihostmap is True, use the force flag.
"""
ssh_cmd = ['svctask', 'mkvdiskhostmap', '-host', '"%s"' % host,
if multihostmap:
return self.run_
Changed in cinder: | |
assignee: | nobody → Gerald McBrearty (gfm-r) |
tags: | added: drivers ibm storwize |
Changed in cinder: | |
importance: | Undecided → Medium |
milestone: | none → mitaka-2 |
Fix proposed to branch: master /review. openstack. org/248225
Review: https:/