Public bug reported:
A negative test case returns an Unexpected API Error, while there is
more detailed message in nova-api.log:
2016-01-12 15:12:49.357 22446 ERROR nova.api.openstack.extensions
NovaException: Unable to find host for Instance
efbbb0cb-fe5f-4047-868e-69305536bcd4
2016-01-12 15:12:49.391 22446 INFO nova.osapi_compute.wsgi.server
[req-e22c4d4d-37c8-443d-8038-15ec3f47d01a 7f0fce3a7e3f479b9933eff3df35649d
65d0c9e644ac4c518e76bc9922ef47ee - - -] 192.168.0.2 "POST
/v2/65d0c9e644ac4c518e76bc9922ef47ee/servers/efbbb0cb-fe5f-4047-868e-69305536bcd4/action
HTTP/1.1" status: 500 len: 428 time: 0.3730938
Steps to reproduce:
1. Create net01: net01__subnet, 192.168.1.0/24:
neutron net-create net01
neutron subnet-create net01 192.168.1.0/24 --enable-dhcp --name net01__subnet
2. Boot an instance vm1 in net01 with incorrect compute node:
NET_ID=$(neutron net-list | grep 'net01' | awk '{print $2}')
nova boot --flavor m1.micro --image TestVM --nic net-id=$NET_ID
--security-groups default --availability-zone
nova:<some-controller-node.domain.tld> vm1
3. Check that the instance is in ERROR state now and isn’t assigned to any host:
nova show vm1 | grep OS-EXT-SRV-ATTR:host && nova show vm1 | grep status
| OS-EXT-SRV-ATTR:host | -
|
| status | ERROR
4. Try to assign fixed IP to the instance vm1 and ensure that it returns an
error:
nova add-fixed-ip vm1 $NET_ID
The expected result:
An error message, something like " Returning 409 to user: Cannot
'attach_interface' instance efbbb0cb-fe5f-4047-868e-69305536bcd4 while it is in
vm_state error " appears
The actual result:
ERROR (ClientException): Unexpected API Error. Please report this at
http://bugs.launchpad.net/nova/ and attach the Nova API log if possible.
<class 'nova.exception.NovaException'> (HTTP 500) (Request-ID:
req-e22c4d4d-37c8-443d-8038-15ec3f47d01a)
appears
Nova version - http://paste.openstack.org/show/483603/
nova-api logs for faulty instance - http://paste.openstack.org/show/483611/
** Affects: nova
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1533260
Title:
Unexpected API Error is returned, when trying to add fixed IP to an
instance in ERROR state
Status in OpenStack Compute (nova):
New
Bug description:
A negative test case returns an Unexpected API Error, while there is
more detailed message in nova-api.log:
2016-01-12 15:12:49.357 22446 ERROR nova.api.openstack.extensions
NovaException: Unable to find host for Instance
efbbb0cb-fe5f-4047-868e-69305536bcd4
2016-01-12 15:12:49.391 22446 INFO nova.osapi_compute.wsgi.server
[req-e22c4d4d-37c8-443d-8038-15ec3f47d01a 7f0fce3a7e3f479b9933eff3df35649d
65d0c9e644ac4c518e76bc9922ef47ee - - -] 192.168.0.2 "POST
/v2/65d0c9e644ac4c518e76bc9922ef47ee/servers/efbbb0cb-fe5f-4047-868e-69305536bcd4/action
HTTP/1.1" status: 500 len: 428 time: 0.3730938
Steps to reproduce:
1. Create net01: net01__subnet, 192.168.1.0/24:
neutron net-create net01
neutron subnet-create net01 192.168.1.0/24 --enable-dhcp --name net01__subnet
2. Boot an instance vm1 in net01 with incorrect compute node:
NET_ID=$(neutron net-list | grep 'net01' | awk '{print $2}')
nova boot --flavor m1.micro --image TestVM --nic net-id=$NET_ID
--security-groups default --availability-zone
nova:<some-controller-node.domain.tld> vm1
3. Check that the instance is in ERROR state now and isn’t assigned to any
host:
nova show vm1 | grep OS-EXT-SRV-ATTR:host && nova show vm1 | grep status
| OS-EXT-SRV-ATTR:host | -
|
| status | ERROR
4. Try to assign fixed IP to the instance vm1 and ensure that it returns an
error:
nova add-fixed-ip vm1 $NET_ID
The expected result:
An error message, something like " Returning 409 to user: Cannot
'attach_interface' instance efbbb0cb-fe5f-4047-868e-69305536bcd4 while it is in
vm_state error " appears
The actual result:
ERROR (ClientException): Unexpected API Error. Please report this at
http://bugs.launchpad.net/nova/ and attach the Nova API log if possible.
<class 'nova.exception.NovaException'> (HTTP 500) (Request-ID:
req-e22c4d4d-37c8-443d-8038-15ec3f47d01a)
appears
Nova version - http://paste.openstack.org/show/483603/
nova-api logs for faulty instance - http://paste.openstack.org/show/483611/
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1533260/+subscriptions
--
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to : [email protected]
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help : https://help.launchpad.net/ListHelp