def __init__(self, root_helper, lio_initiator_iqns='',
iscsi_target_prefix='iqn.2010-10.org.openstack:',
execute=putils.execute):
- super(LioAdm, self).__init__('rtstool', root_helper, execute)
+ super(LioAdm, self).__init__('cinder-rtstool', root_helper, execute)
self.iscsi_target_prefix = iscsi_target_prefix
self.lio_initiator_iqns = lio_initiator_iqns
def _verify_rtstool(self):
try:
- self._execute('rtstool', 'verify')
+ self._execute('cinder-rtstool', 'verify')
except (OSError, putils.ProcessExecutionError):
- LOG.error(_('rtstool is not installed correctly'))
+ LOG.error(_('cinder-rtstool is not installed correctly'))
raise
def _get_target(self, iqn):
- (out, err) = self._execute('rtstool',
+ (out, err) = self._execute('cinder-rtstool',
'get-targets',
run_as_root=True)
lines = out.split('\n')
extra_args.append(self.lio_initiator_iqns)
try:
- command_args = ['rtstool',
+ command_args = ['cinder-rtstool',
'create',
path,
name,
iqn = '%s%s' % (self.iscsi_target_prefix, vol_uuid_name)
try:
- self._execute('rtstool',
+ self._execute('cinder-rtstool',
'delete',
iqn,
run_as_root=True)
# Add initiator iqns to target ACL
try:
- self._execute('rtstool', 'add-initiator',
+ self._execute('cinder-rtstool', 'add-initiator',
volume_iqn,
auth_user,
auth_pass,
self.persist_tempdir = tempfile.mkdtemp()
self.flags(iscsi_helper='lioadm')
self.script_template = "\n".join([
- 'rtstool create '
+ 'cinder-rtstool create '
'/foo iqn.2011-09.org.foo.bar:blaa test_id test_pass',
- 'rtstool delete iqn.2010-10.org.openstack:volume-blaa'])
+ 'cinder-rtstool delete iqn.2010-10.org.openstack:volume-blaa'])
class ISERTgtAdmTestCase(TgtAdmTestCase):
ietadm: CommandFilter, ietadm, root
tgtadm: CommandFilter, tgtadm, root
tgt-admin: CommandFilter, tgt-admin, root
-rtstool: CommandFilter, rtstool, root
+cinder-rtstool: CommandFilter, cinder-rtstool, root
# cinder/volume/driver.py: 'vgs', '--noheadings', '-o', 'name'
vgs: CommandFilter, vgs, root