In this case subnet a404dc60-62ab-4c2c-bf24-2ab33df6f176 can't be deleted.
Port 375d726d-fccd-42e4-8b5f-60a200ed76af is in this subnet, and attach to instance c65d83f5-db85-4adf-b8ae-bba2b81ac4c6
At nova api side, the port attach at:
2014-09-21 05:27:06.453 AUDIT nova.api.openstack.compute.contrib.attach_interfaces [req-d547ba16-49ec-468c-a2d3-00075880f33b TestNetworkBasicOps-1044489211 TestNetworkBasicOps-84164684] [instance: c65d83f5-db85-4adf-b8ae-bba2b81ac4c6] Attach interface
But the detach failed
2014-09-21 05:27:11.047 ERROR oslo.messaging.rpc.dispatcher [req-035307f9-819f-4489-aea0-ce18f00ec2f5 TestNetworkBasicOps-1044489211 TestNetworkBasicOps-84164684] Exception during message handling: Port 375d726d-fccd-42e4-8b5f-60a200ed76af is not attached
2014-09-21 05:27:11.047 4710 TRACE oslo.messaging.rpc.dispatcher Traceback (most recent call last):
....
So the reason is detach happend before attach finished.
The failed test is:
def test_hotplug_nic(self):
"""
1. create a new network, with no gateway (to prevent overwriting VM's gateway)
2. connect VM to new network
3. set static ip and bring new nic up
4. check VM can ping new network dhcp port
self._hotplug_server() attach the interface, but there won't waiting for the interface attachment finished.
and 'self._check_network_internal_connectivity(network=self.new_net)' only check the interface created when boot instance and dhcp interface.
So the cleanup may happened before attach interface finished.
But this cleanup failed as the log:
2014-09-21 05:27:11.047 ERROR oslo.messaging.rpc.dispatcher [req-035307f9-819f-4489-aea0-ce18f00ec2f5 TestNetworkBasicOps-1044489211 TestNetworkBasicOps-84164684] Exception during message handling: Port 375d726d-fccd-42e4-8b5f-60a200ed76af is not attached
And another cleanup is waiting for the interface deleted, self.addCleanup(self.network_client.wait_for_resource_deletion, 'port', interface['port_id'])
Except the case fixed by https:/ /review. openstack. org/#/c/ 122986/, there also a race in tempest test.
The analyze is based on: logs.openstack. org/73/ 122873/ 1/gate/ gate-tempest- dsvm-neutron- full/e5a2bf6/ console. html
http://
In this case subnet a404dc60- 62ab-4c2c- bf24-2ab33df6f1 76 can't be deleted. fccd-42e4- 8b5f-60a200ed76 af is in this subnet, and attach to instance c65d83f5- db85-4adf- b8ae-bba2b81ac4 c6
Port 375d726d-
At nova api side, the port attach at: openstack. compute. contrib. attach_ interfaces [req-d547ba16- 49ec-468c- a2d3-00075880f3 3b TestNetworkBasi cOps-1044489211 TestNetworkBasi cOps-84164684] [instance: c65d83f5- db85-4adf- b8ae-bba2b81ac4 c6] Attach interface
2014-09-21 05:27:06.453 AUDIT nova.api.
and detach at: openstack. compute. contrib. attach_ interfaces [req-035307f9- 819f-4489- aea0-ce18f00ec2 f5 TestNetworkBasi cOps-1044489211 TestNetworkBasi cOps-84164684] [instance: c65d83f5- db85-4adf- b8ae-bba2b81ac4 c6] Detach interface 375d726d- fccd-42e4- 8b5f-60a200ed76 af
2014-09-21 05:27:10.937 AUDIT nova.api.
But the detach failed rpc.dispatcher [req-035307f9- 819f-4489- aea0-ce18f00ec2 f5 TestNetworkBasi cOps-1044489211 TestNetworkBasi cOps-84164684] Exception during message handling: Port 375d726d- fccd-42e4- 8b5f-60a200ed76 af is not attached rpc.dispatcher Traceback (most recent call last):
2014-09-21 05:27:11.047 ERROR oslo.messaging.
2014-09-21 05:27:11.047 4710 TRACE oslo.messaging.
....
So the reason is detach happend before attach finished.
The failed test is:
def test_hotplug_ nic(self) :
gateway)
"""
1. create a new network, with no gateway (to prevent overwriting VM's
2. connect VM to new network
3. set static ip and bring new nic up
4. check VM can ping new network dhcp port
"""
self._ setup_network_ and_servers( )
self._ check_public_ network_ connectivity( should_ connect= True)
self._ create_ new_network( )
self._ hotplug_ server( )
self._ check_network_ internal_ connectivity( network= self.new_ net)
self._hotplug_ server( ) attach the interface, but there won't waiting for the interface attachment finished. check_network_ internal_ connectivity( network= self.new_ net)' only check the interface created when boot instance and dhcp interface.
and 'self._
So the cleanup may happened before attach interface finished.
The cleanup is setup at 'self._ hotplug_ server'
But this cleanup failed as the log: rpc.dispatcher [req-035307f9- 819f-4489- aea0-ce18f00ec2 f5 TestNetworkBasi cOps-1044489211 TestNetworkBasi cOps-84164684] Exception during message handling: Port 375d726d- fccd-42e4- 8b5f-60a200ed76 af is not attached
2014-09-21 05:27:11.047 ERROR oslo.messaging.
And another cleanup is waiting for the interface deleted,
self.addCleanu p(self. network_ client. wait_for_ resource_ deletion,
'port' ,
interface[ 'port_id' ])
We also can found this cleanup timeout finally logs.openstack. org/73/ 122873/ 1/gate/ gate-tempest- dsvm-neutron- full/e5a2bf6/ console. html#_2014- 09-21_05_ 41_32_226
http://
So for this case, we should fix the tempest test, to waiting for attach interface down.