From 571ac18e7c4109fc9728a0ee27f04887f1d8aeea Mon Sep 17 00:00:00 2001 From: Eric Harney Date: Tue, 27 May 2014 10:11:53 -0400 Subject: [PATCH] Fix ISER scan retry option The 'num_iscsi_scan_tries' option was renamed to 'num_volume_device_scan_tries'. Remove it from the test where the deprecated name is referenced since it is not used there anyway. Fix the ISER driver to set the new config field rather than the old one. Presumably this made the num_iser_scan_tries option not work since only the new field is passed to the brick connector. Closes-Bug: #1323741 Change-Id: I13ac4cce10894b541054fbda719bbc5fd555e3c1 --- cinder/tests/test_volume.py | 1 - cinder/volume/driver.py | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/cinder/tests/test_volume.py b/cinder/tests/test_volume.py index a0016af73..34fd46718 100644 --- a/cinder/tests/test_volume.py +++ b/cinder/tests/test_volume.py @@ -3046,7 +3046,6 @@ class ISCSITestCase(DriverTestCase): def setUp(self): super(ISCSITestCase, self).setUp() self.configuration = mox.MockObject(conf.Configuration) - self.configuration.num_iscsi_scan_tries = 3 self.configuration.iscsi_num_targets = 100 self.configuration.iscsi_target_prefix = 'iqn.2010-10.org.openstack:' self.configuration.iscsi_ip_address = '0.0.0.0' diff --git a/cinder/volume/driver.py b/cinder/volume/driver.py index 56c92ba91..0852e29ca 100644 --- a/cinder/volume/driver.py +++ b/cinder/volume/driver.py @@ -939,7 +939,7 @@ class ISERDriver(ISCSIDriver): def __init__(self, *args, **kwargs): super(ISERDriver, self).__init__(*args, **kwargs) # for backward compatibility - self.configuration.num_iscsi_scan_tries = \ + self.configuration.num_volume_device_scan_tries = \ self.configuration.num_iser_scan_tries self.configuration.iscsi_num_targets = \ self.configuration.iser_num_targets -- 2.45.2