Description of problem: After system board replacement on overcloud node, MAC address of provisioning NIC got changed, tried to update the new MAC address on existing ironic-port after putting the ironic node in maintenance mode but no luck. Version-Release number of selected component (if applicable): RHEL OSP 7 RHEL OSP 8 How reproducible: Everytime. Steps to Reproduce: 1. Setting the ironic node in maintenance mode. ~~~ [root@instack ~]# ironic node-set-maintenance 81749da2-7d34-4e0f8ceb-4f5cbb26158f True [root@instack ~]# ironic node-list | grep -i '81749da2-7d34-4e0f-8ceb-4f5cbb26158f' | 81749da2-7d34-4e0f-8ceb-4f5cbb26158f | None | 4781e6f9-0dfa-4f36-b915-4cf3d6e5524a | power on | active | True | ~~~ 2. Checking the ironic port details. ~~~ [root@instack ~]# ironic port-list --detail | grep '81749da2-7d34-4e0f-8ceb-4f5cbb26158f' | cb5fd243-bd78-4522-b27e-0fa0be1e2dea | 00:1a:7a:f5:b5:53 | 2016-07-21T12:49:30+00:00 | {u'vif_port_id': u'09eba91e-1360-4a16-84bc-382b8630bb89'} | 81749da2-7d34-4e0f-8ceb-4f5cbb26158f | 2016-08-10T09:08:52+00:00 | [root@instack ~]# ironic port-show cb5fd243-bd78-4522-b27e-0fa0be1e2dea +------------+-----------------------------------------------------------+ | Property | Value | +------------+-----------------------------------------------------------+ | node_uuid | 81749da2-7d34-4e0f-8ceb-4f5cbb26158f | | uuid | cb5fd243-bd78-4522-b27e-0fa0be1e2dea | | extra | {u'vif_port_id': u'09eba91e-1360-4a16-84bc-382b8630bb89'} | | created_at | 2016-07-21T12:49:30+00:00 | | updated_at | 2016-08-10T09:08:52+00:00 | | address | 00:1a:7a:f5:b5:53 | +------------+-----------------------------------------------------------+ ~~~ 3. Error coming on terminal while updating the MAC address. ~~~ [root@instack ~]# ironic port-update cb5fd243-bd78-4522-b27e-0fa0be1e2dea replace address=00:1a:7a:f5:b5:50 Update MAC address on port: 09eba91e-1360-4a16-84bc-382b8630bb89 failed. (HTTP 500) ~~~ Call trace seen in /var/log/ironic/ironic-api.log ~~~ 2016-08-10 10:11:09.909 4890 ERROR wsme.api [req-54c024e0-f46a-49a5-97df-2f04851b1ad3 ] Server-side error: "Update MAC address on port: 09eba91e-1360-4a16-84bc-382b8630bb89 failed. Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/server.py", line 142, in inner return func(*args, **kwargs) File "/usr/lib/python2.7/site-packages/ironic/conductor/manager.py", line 1728, in update_port token=context.auth_token) File "/usr/lib/python2.7/site-packages/ironic/dhcp/neutron.py", line 145, in update_port_address raise exception.FailedToUpdateMacOnPort(port_id=port_id) FailedToUpdateMacOnPort: Update MAC address on port: 09eba91e-1360-4a16-84bc-382b8630bb89 failed. ". Detail: Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/wsmeext/pecan.py", line 84, in callfunction result = f(self, *args, **kwargs) File "/usr/lib/python2.7/site-packages/ironic/api/controllers/v1/port.py", line 402, in patch pecan.request.context, rpc_port, topic) File "/usr/lib/python2.7/site-packages/ironic/conductor/rpcapi.py", line 435, in update_port return cctxt.call(context, 'update_port', port_obj=port_obj) File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/client.py", line 158, in call retry=self.retry) File "/usr/lib/python2.7/site-packages/oslo_messaging/transport.py", line 90, in _send timeout=timeout, retry=retry) File "/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py", line 431, in send retry=retry) File "/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py", line 422, in _send raise result FailedToUpdateMacOnPort_Remote: Update MAC address on port: 09eba91e-1360-4a16-84bc-382b8630bb89 failed. Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/server.py", line 142, in inner return func(*args, **kwargs) File "/usr/lib/python2.7/site-packages/ironic/conductor/manager.py", line 1728, in update_port token=context.auth_token) File "/usr/lib/python2.7/site-packages/ironic/dhcp/neutron.py", line 145, in update_port_address raise exception.FailedToUpdateMacOnPort(port_id=port_id) FailedToUpdateMacOnPort: Update MAC address on port: 09eba91e-1360-4a16-84bc-382b8630bb89 failed. ~~~ Actual results: it's not allowing us to change the MAC address. Expected results: It should allow us to change the MAC address. Additional info: as soon as we remove the binding from corresponding to neutron port. Able to update the MAC address without any issue. [root@instack ~]# neutron port-update 09eba91e-1360-4a16-84bc-382b8630bb89 --binding:host_id Updated port: 09eba91e-1360-4a16-84bc-382b8630bb89 Checking the port status. [root@instack ~]# ironic port-show cb5fd243-bd78-4522-b27e-0fa0be1e2dea +------------+-----------------------------------------------------------+ | Property | Value | +------------+-----------------------------------------------------------+ | node_uuid | 81749da2-7d34-4e0f-8ceb-4f5cbb26158f | | uuid | cb5fd243-bd78-4522-b27e-0fa0be1e2dea | | extra | {u'vif_port_id': u'09eba91e-1360-4a16-84bc-382b8630bb89'} | | created_at | 2016-07-21T12:49:30+00:00 | | updated_at | 2016-08-10T09:08:52+00:00 | | address | 00:1a:7a:f5:b5:53 | +------------+-----------------------------------------------------------+ As neutron binding is removed hence we would be able to update the MAC address now without deleting and creating the port. [root@instack ~]# ironic port-update cb5fd243-bd78-4522-b27e-0fa0be1e2dea replace address=00:1a:7a:f5:b5:50 +------------+-----------------------------------------------------------+ | Property | Value | +------------+-----------------------------------------------------------+ | node_uuid | 81749da2-7d34-4e0f-8ceb-4f5cbb26158f | | uuid | cb5fd243-bd78-4522-b27e-0fa0be1e2dea | | extra | {u'vif_port_id': u'09eba91e-1360-4a16-84bc-382b8630bb89'} | | created_at | 2016-07-21T12:49:30+00:00 | | updated_at | 2016-08-10T14:16:13+00:00 | | address | 00:1a:7a:f5:b5:50 | +------------+-----------------------------------------------------------+
The patch is on review upstream.
The patch https://review.openstack.org/#/c/353450/ merged into master (OSP10) and will probably get backported upstream into OSP9. If you need other versions, please clone this bug and target to an appropriate version (incl. flags).
This was merged to stable/mitaka months ago. Jon, any ideas why it's still not in puddles?
mitaka eol-tag 5.1.3 includes this fix, rebasing based on request from Dmitry Tantsur
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2017:3224