diff --git a/devstack/plugin.sh b/devstack/plugin.sh index 675e3110de..f9b769c2d6 100755 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -405,10 +405,10 @@ function configure_data_service_generic_driver { if [[ $share_driver == $generic_driver ]]; then driver_handles_share_servers=$(iniget $MANILA_CONF ${enabled_backends[0]} driver_handles_share_servers) if [[ $(trueorfalse False driver_handles_share_servers) == False ]]; then - iniset $MANILA_CONF DEFAULT data_node_access_ip $PUBLIC_NETWORK_GATEWAY + iniset $MANILA_CONF DEFAULT data_node_access_ips $PUBLIC_NETWORK_GATEWAY else if ! [[ -z $MANILA_DATA_NODE_IP ]]; then - iniset $MANILA_CONF DEFAULT data_node_access_ip $MANILA_DATA_NODE_IP + iniset $MANILA_CONF DEFAULT data_node_access_ips $MANILA_DATA_NODE_IP fi fi fi @@ -658,7 +658,7 @@ function init_manila { cat $STACK_HOME/.ssh/*.pub >> $SSH_USER_HOME/.ssh/authorized_keys # Give ssh user sudo access echo "$MANILA_ZFSONLINUX_SSH_USERNAME ALL=(ALL) NOPASSWD: ALL" | sudo tee -a /etc/sudoers > /dev/null - iniset $MANILA_CONF DEFAULT data_node_access_ip $MANILA_ZFSONLINUX_SERVICE_IP + iniset $MANILA_CONF DEFAULT data_node_access_ips $MANILA_ZFSONLINUX_SERVICE_IP fi fi fi @@ -815,7 +815,7 @@ function configure_samba { iniset $MANILA_CONF $backend_name driver_handles_share_servers False iniset $MANILA_CONF $backend_name lvm_share_export_ips $MANILA_LVM_SHARE_EXPORT_IPS done - iniset $MANILA_CONF DEFAULT data_node_access_ip $HOST_IP + iniset $MANILA_CONF DEFAULT data_node_access_ips $HOST_IP fi } @@ -1062,14 +1062,14 @@ function setup_ipv6 { for backend_name in ${MANILA_ENABLED_BACKENDS//,/ }; do iniset $MANILA_CONF $backend_name lvm_share_export_ips $public_gateway_ipv4,$public_gateway_ipv6 done - iniset $MANILA_CONF DEFAULT data_node_access_ip $public_gateway_ipv4 + iniset $MANILA_CONF DEFAULT data_node_access_ips $public_gateway_ipv4 fi if [ "$SHARE_DRIVER" == "manila.share.drivers.cephfs.driver.CephFSDriver" ]; then for backend_name in ${MANILA_ENABLED_BACKENDS//,/ }; do iniset $MANILA_CONF $backend_name cephfs_ganesha_export_ips $public_gateway_ipv4,$public_gateway_ipv6 done - iniset $MANILA_CONF DEFAULT data_node_access_ip $public_gateway_ipv4 + iniset $MANILA_CONF DEFAULT data_node_access_ips $public_gateway_ipv4 fi # install Quagga for setting up the host routes dynamically diff --git a/doc/source/admin/shared-file-systems-share-migration.rst b/doc/source/admin/shared-file-systems-share-migration.rst index 769e07d965..cbabd63c7d 100644 --- a/doc/source/admin/shared-file-systems-share-migration.rst +++ b/doc/source/admin/shared-file-systems-share-migration.rst @@ -186,9 +186,10 @@ must use manila share access APIs to grant access to mount the instances. The access rule type varies according to the share protocol, so there are a few config options to set the access value for each type: -* ``data_node_access_ip``: For IP-based access type, provide the value of the - IP of the Data Service node in the administrator network. For NFS shares, - drivers should always add rules with the "no_root_squash" property. +* ``data_node_access_ips``: For IP-based access type, provide one or more + administrator network IP addresses of the host running the Data Service. + For NFS shares, drivers should always add rules with the "no_root_squash" + property. * ``data_node_access_cert``: For certificate-based access type, provide the value of the certificate name that grants access to the Data Service. diff --git a/doc/source/configuration/shared-file-systems/drivers/hitachi-hnas-driver.rst b/doc/source/configuration/shared-file-systems/drivers/hitachi-hnas-driver.rst index 148f1f6c59..a14dcc0ee8 100644 --- a/doc/source/configuration/shared-file-systems/drivers/hitachi-hnas-driver.rst +++ b/doc/source/configuration/shared-file-systems/drivers/hitachi-hnas-driver.rst @@ -331,7 +331,7 @@ Extra configuration is needed for allowing shares to be migrated from or to HNAS. In the OpenStack deployment, the manila-share node needs an additional connection to the EVS data interface. Furthermore, make sure to add ``hitachi_hnas_admin_network_ip`` to the configuration. This should match the -value of ``data_node_access_ip``. For more in-depth documentation, +value of ``data_node_access_ips``. For more in-depth documentation, refer to the `share migration documents <https://docs.openstack.org/manila/latest/admin/shared-file-systems-share-migration.html>`_ diff --git a/doc/source/configuration/tables/manila-common.inc b/doc/source/configuration/tables/manila-common.inc index 1b5d2c5b4c..5b6686d47e 100644 --- a/doc/source/configuration/tables/manila-common.inc +++ b/doc/source/configuration/tables/manila-common.inc @@ -32,8 +32,8 @@ - (String) The admin user name registered in the security service in order to allow access to user authentication-based shares. * - ``data_node_access_cert`` = ``None`` - (String) The certificate installed in the data node in order to allow access to certificate authentication-based shares. - * - ``data_node_access_ip`` = ``None`` - - (String) The IP of the node interface connected to the admin network. Used for allowing access to the mounting shares. + * - ``data_node_access_ips`` = ``None`` + - (String) A list of the IPs of the node interface connected to the admin network. Used for allowing access to the mounting shares. Default is []. * - ``data_node_mount_options`` = ``{}`` - (Dict) Mount options to be included in the mount command for share protocols. Use dictionary format, example: {'nfs': '-o nfsvers=3', 'cifs': '-o user=foo,pass=bar'} * - ``data_topic`` = ``manila-data`` diff --git a/manila/data/helper.py b/manila/data/helper.py index 64ec72df95..22e815efec 100644 --- a/manila/data/helper.py +++ b/manila/data/helper.py @@ -39,14 +39,6 @@ data_helper_opts = [ help="A list of the IPs of the node interface connected to " "the admin network. Used for allowing access to the " "mounting shares. Default is []."), - cfg.StrOpt( - 'data_node_access_ip', - help="The IP of the node interface connected to the admin network. " - "Used for allowing access to the mounting shares.", - deprecated_for_removal=True, - deprecated_reason="New config option 'data_node_access_ips' added " - "to support multiple IPs, including IPv6 addresses " - "alongside IPv4."), cfg.StrOpt( 'data_node_access_cert', help="The certificate installed in the data node in order to " @@ -217,7 +209,7 @@ class DataServiceHelper(object): if access_type.lower() == 'cert' and CONF.data_node_access_cert: access_to_list.append(CONF.data_node_access_cert) elif access_type.lower() == 'ip': - ips = CONF.data_node_access_ips or CONF.data_node_access_ip + ips = CONF.data_node_access_ips if ips: if not isinstance(ips, list): ips = [ips] diff --git a/manila/tests/data/test_helper.py b/manila/tests/data/test_helper.py index e6360b306a..6f32f21381 100644 --- a/manila/tests/data/test_helper.py +++ b/manila/tests/data/test_helper.py @@ -124,7 +124,7 @@ class DataServiceHelperTestCase(test.TestCase): def test__get_access_entries_according_to_mapping(self, mapping): data_copy_helper.CONF.data_node_access_cert = 'fake' - data_copy_helper.CONF.data_node_access_ip = 'fake' + data_copy_helper.CONF.data_node_access_ips = 'fake' data_copy_helper.CONF.data_node_access_admin_user = 'fake' expected = [{ 'access_type': list(mapping.keys())[0], @@ -145,7 +145,7 @@ class DataServiceHelperTestCase(test.TestCase): def test__get_access_entries_according_to_mapping_exception_not_set(self): - data_copy_helper.CONF.data_node_access_ip = None + data_copy_helper.CONF.data_node_access_ips = None self.assertRaises( exception.ShareDataCopyFailed, @@ -155,7 +155,6 @@ class DataServiceHelperTestCase(test.TestCase): ips = ['fake1', 'fake2'] data_copy_helper.CONF.data_node_access_ips = ips - data_copy_helper.CONF.data_node_access_ip = None expected = [{ 'access_type': 'ip', diff --git a/releasenotes/notes/bug-1745436-remove-data-node-access-ip-config-opt-709f330c57cdb0d5.yaml b/releasenotes/notes/bug-1745436-remove-data-node-access-ip-config-opt-709f330c57cdb0d5.yaml new file mode 100644 index 0000000000..c8d654826e --- /dev/null +++ b/releasenotes/notes/bug-1745436-remove-data-node-access-ip-config-opt-709f330c57cdb0d5.yaml @@ -0,0 +1,7 @@ +--- +upgrade: + - | + The configuration option for the manila-data service, + ``data_node_access_ip`` from the [DEFAULT] section is no longer + supported. It was deprecated in favor of ``data_node_access_ips`` in the + OpenStack Shared File Systems (manila) service release 6.0.0 (Queens).