From: Ryan LIANG Date: Wed, 3 Feb 2016 08:40:03 +0000 (-0800) Subject: VNX: Set timeout for naviseccli X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=4fe875a199e407970686d6f4159e5f15de0528db;p=openstack-build%2Fcinder-build.git VNX: Set timeout for naviseccli Add -timeout option to all naviseccli commands, the value is 120 sec. Change-Id: Ib3b35da6766b5db69395b89debd50c54d69eec00 Closes-Bug: 1546412 --- diff --git a/cinder/tests/unit/test_emc_vnx.py b/cinder/tests/unit/test_emc_vnx.py index d4f3f2acd..a98759b3c 100644 --- a/cinder/tests/unit/test_emc_vnx.py +++ b/cinder/tests/unit/test_emc_vnx.py @@ -5492,9 +5492,9 @@ class EMCVNXCLIDriverFCTestCase(DriverTestCaseBase): class EMCVNXCLIToggleSPTestData(object): def FAKE_COMMAND_PREFIX(self, sp_address): - return ('/opt/Navisphere/bin/naviseccli', '-address', sp_address, - '-user', 'sysadmin', '-password', 'sysadmin', - '-scope', 'global') + return ('/opt/Navisphere/bin/naviseccli', '-timeout 120', + '-address', sp_address, '-user', 'sysadmin', + '-password', 'sysadmin', '-scope', 'global') class EMCVNXCLIToggleSPTestCase(test.TestCase): diff --git a/cinder/volume/drivers/emc/emc_vnx_cli.py b/cinder/volume/drivers/emc/emc_vnx_cli.py index 2a247bf50..76f4bbac2 100644 --- a/cinder/volume/drivers/emc/emc_vnx_cli.py +++ b/cinder/volume/drivers/emc/emc_vnx_cli.py @@ -688,7 +688,7 @@ class CommandLineHelper(object): LOG.error(err_msg) raise exception.VolumeBackendAPIException(data=err_msg) - self.command = (navisecclipath, '-address') + self.command = (navisecclipath, '-timeout 120', '-address') self.active_storage_ip = configuration.san_ip self.primary_storage_ip = self.active_storage_ip self.secondary_storage_ip = configuration.san_secondary_ip