diff options
7 files changed, 33 insertions, 6 deletions
diff --git a/ironic/common/neutron.py b/ironic/common/neutron.py index e81f360aa..c34e1039e 100644 --- a/ironic/common/neutron.py +++ b/ironic/common/neutron.py @@ -344,7 +344,8 @@ def add_ports_to_network(task, network_uuid, security_groups=None): wait_for_host_agent( client, update_port_attrs['binding:host_id']) port = client.create_port(**port_attrs) - update_neutron_port(task.context, port.id, update_port_attrs) + port = update_neutron_port(task.context, port.id, + update_port_attrs) if CONF.neutron.dhcpv6_stateful_address_count > 1: _add_ip_addresses_for_ipv6_stateful(task.context, port, client) if is_smart_nic: diff --git a/ironic/drivers/modules/drac/management.py b/ironic/drivers/modules/drac/management.py index ce864b79c..a1435d168 100644 --- a/ironic/drivers/modules/drac/management.py +++ b/ironic/drivers/modules/drac/management.py @@ -207,7 +207,7 @@ def set_boot_device(node, device, persistent=False): client.delete_jobs(job_ids=[job.id for job in unfinished_jobs]) if validate_job_queue: - drac_job.validate_job_queue(node) + drac_job.validate_job_queue(node, name_prefix="Configure: BIOS") try: drac_boot_devices = client.list_boot_devices() diff --git a/ironic/tests/unit/common/test_neutron.py b/ironic/tests/unit/common/test_neutron.py index a40723a85..5d5b250a3 100644 --- a/ironic/tests/unit/common/test_neutron.py +++ b/ironic/tests/unit/common/test_neutron.py @@ -289,11 +289,13 @@ class TestNeutronNetworkActions(db_base.DbTestCase): fixed_ips=[]) self.client_mock.create_port.side_effect = [self.neutron_port, neutron_port2] + update_mock.side_effect = [self.neutron_port, neutron_port2] expected = {port.uuid: self.neutron_port.id, port2.uuid: neutron_port2.id} else: self.client_mock.create_port.return_value = self.neutron_port + update_mock.return_value = self.neutron_port expected = {port.uuid: self.neutron_port['id']} with task_manager.acquire(self.context, self.node.uuid) as task: @@ -457,6 +459,7 @@ class TestNeutronNetworkActions(db_base.DbTestCase): vpi_mock.return_value = True # Ensure we can create ports self.client_mock.create_port.return_value = self.neutron_port + update_mock.return_value = self.neutron_port expected = {port.uuid: self.neutron_port.id} with task_manager.acquire(self.context, self.node.uuid) as task: ports = neutron.add_ports_to_network(task, self.network_uuid) @@ -491,6 +494,7 @@ class TestNeutronNetworkActions(db_base.DbTestCase): ) self.client_mock.create_port.side_effect = [ self.neutron_port, openstack_exc.OpenStackCloudException] + update_mock.return_value = self.neutron_port with task_manager.acquire(self.context, self.node.uuid) as task: neutron.add_ports_to_network(task, self.network_uuid) self.assertIn("Could not create neutron port for node's", @@ -988,6 +992,7 @@ class TestNeutronNetworkActions(db_base.DbTestCase): # Ensure we can create ports self.client_mock.create_port.return_value = self.neutron_port + update_mock.return_value = self.neutron_port expected = {port.uuid: self.neutron_port.id} with task_manager.acquire(self.context, self.node.uuid) as task: ports = neutron.add_ports_to_network(task, self.network_uuid) diff --git a/ironic/tests/unit/drivers/modules/drac/test_management.py b/ironic/tests/unit/drivers/modules/drac/test_management.py index 0a8f1d895..02a9c4c52 100644 --- a/ironic/tests/unit/drivers/modules/drac/test_management.py +++ b/ironic/tests/unit/drivers/modules/drac/test_management.py @@ -278,7 +278,8 @@ class DracManagementInternalMethodsTestCase(test_utils.BaseDracTest): self.assertEqual(0, mock_list_unfinished_jobs.call_count) self.assertEqual(0, mock_client.delete_jobs.call_count) - mock_validate_job_queue.assert_called_once_with(self.node) + mock_validate_job_queue.assert_called_once_with( + self.node, name_prefix="Configure: BIOS") mock_client.change_boot_device_order.assert_called_once_with( 'OneTime', 'BIOS.Setup.1-1#BootSeq#NIC.Embedded.1-1-1') self.assertEqual(0, mock_client.set_bios_settings.call_count) @@ -542,7 +543,8 @@ class DracManagementInternalMethodsTestCase(test_utils.BaseDracTest): self.assertEqual(0, mock_list_unfinished_jobs.call_count) self.assertEqual(0, mock_client.delete_jobs.call_count) - mock_validate_job_queue.assert_called_once_with(self.node) + mock_validate_job_queue.assert_called_once_with( + self.node, name_prefix="Configure: BIOS") @mock.patch.object(drac_job, 'validate_job_queue', spec_set=True, autospec=True) @@ -593,7 +595,8 @@ class DracManagementInternalMethodsTestCase(test_utils.BaseDracTest): self.assertEqual(0, mock_list_unfinished_jobs.call_count) self.assertEqual(0, mock_client.delete_jobs.call_count) - mock_validate_job_queue.assert_called_once_with(self.node) + mock_validate_job_queue.assert_called_once_with( + self.node, name_prefix="Configure: BIOS") @mock.patch.object(drac_mgmt, '_get_next_persistent_boot_mode', spec_set=True, autospec=True) diff --git a/releasenotes/notes/fix-idrac-wsman-deploy-with-existing-non-bios-jobs-78aa2195d0c3016f.yaml b/releasenotes/notes/fix-idrac-wsman-deploy-with-existing-non-bios-jobs-78aa2195d0c3016f.yaml new file mode 100644 index 000000000..b9382d3b9 --- /dev/null +++ b/releasenotes/notes/fix-idrac-wsman-deploy-with-existing-non-bios-jobs-78aa2195d0c3016f.yaml @@ -0,0 +1,12 @@ +--- +fixes: + - | + Fixes ``idrac-wsman`` management interface ``set_boot_device`` method that + would fail deployment when there are existing jobs present with error + "Failed to change power state to ''power on'' by ''rebooting''. Error: DRAC + operation failed. Reason: Unfinished config jobs found: <list of existing + jobs>. Make sure they are completed before retrying.". Now there can be + non-BIOS jobs present during deployment. This will still fail for cases + when there are BIOS jobs present. In such cases should consider moving to + ``idrac-redfish`` that does not have this limitation when setting boot + device.
\ No newline at end of file diff --git a/releasenotes/notes/fix-ipv6-provisioning-routed-provider-network-bbd0c46559f618ac.yaml b/releasenotes/notes/fix-ipv6-provisioning-routed-provider-network-bbd0c46559f618ac.yaml new file mode 100644 index 000000000..beb270f61 --- /dev/null +++ b/releasenotes/notes/fix-ipv6-provisioning-routed-provider-network-bbd0c46559f618ac.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + Fixed an issue where provisioning/cleaning would fail on IPv6 routed provider + networks. See bug: + `2009773 <https://storyboard.openstack.org/#!/story/2009773>`_. diff --git a/zuul.d/ironic-jobs.yaml b/zuul.d/ironic-jobs.yaml index 355260f2b..a1c09c6d1 100644 --- a/zuul.d/ironic-jobs.yaml +++ b/zuul.d/ironic-jobs.yaml @@ -47,7 +47,7 @@ IRONIC_TEMPEST_WHOLE_DISK_IMAGE: False IRONIC_VM_COUNT: 2 IRONIC_VM_EPHEMERAL_DISK: 1 - IRONIC_VM_SPECS_RAM: 3072 + IRONIC_VM_SPECS_RAM: 2600 IRONIC_VM_LOG_DIR: '{{ devstack_base_dir }}/ironic-bm-logs' # NOTE(dtantsur): in some jobs we end up with 12 disks total, so reduce # each of them. For don't need all 10 GiB for CirrOS anyway. |