diff --git a/cinder/tests/test_ibm_xiv_ds8k.py b/cinder/tests/test_ibm_xiv_ds8k.py index 519bc3ac09c..1ce1d7eae1b 100644 --- a/cinder/tests/test_ibm_xiv_ds8k.py +++ b/cinder/tests/test_ibm_xiv_ds8k.py @@ -124,6 +124,7 @@ class XIVDS8KVolumeDriverTest(test.TestCase): configuration.xiv_ds8k_proxy = \ 'cinder.tests.test_ibm_xiv_ds8k.XIVDS8KFakeProxyDriver' configuration.xiv_ds8k_connection_type = 'iscsi' + configuration.xiv_chap = 'disabled' configuration.san_ip = FAKE configuration.san_login = FAKE configuration.san_clustername = FAKE diff --git a/cinder/volume/drivers/ibm/xiv_ds8k.py b/cinder/volume/drivers/ibm/xiv_ds8k.py index af50e22aca4..179c5d60306 100644 --- a/cinder/volume/drivers/ibm/xiv_ds8k.py +++ b/cinder/volume/drivers/ibm/xiv_ds8k.py @@ -39,6 +39,11 @@ xiv_ds8k_opts = [ default='iscsi', help='Connection type to the IBM Storage Array' ' (fibre_channel|iscsi)'), + cfg.StrOpt( + 'xiv_chap', + default='disabled', + help='CHAP authentication mode, effective only for iscsi' + ' (disabled|enabled)'), ] CONF = cfg.CONF @@ -71,7 +76,8 @@ class XIVDS8KDriver(san.SanDriver): "xiv_ds8k_address": self.configuration.san_ip, "xiv_ds8k_vol_pool": self.configuration.san_clustername, "xiv_ds8k_connection_type": - self.configuration.xiv_ds8k_connection_type + self.configuration.xiv_ds8k_connection_type, + "xiv_chap": self.configuration.xiv_chap }, LOG, exception, diff --git a/etc/cinder/cinder.conf.sample b/etc/cinder/cinder.conf.sample index 88b80282260..cfb4465b2d1 100644 --- a/etc/cinder/cinder.conf.sample +++ b/etc/cinder/cinder.conf.sample @@ -1244,6 +1244,10 @@ # (fibre_channel|iscsi) (string value) #xiv_ds8k_connection_type=iscsi +# CHAP authentication mode, effective only for iscsi +# (disabled|enabled) (string value) +#xiv_chap=disabled + # # Options defined in cinder.volume.drivers.lvm