Can't force-delete instance with task_state not 'None'
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Medium
|
Rajesh Tailor |
Bug Description
Problem Description:
When user tries to force-delete instance which is not in task_state 'None', throws 500 error on console, as below:
ERROR (ClientException): Unexpected API Error. Please report this at http://
<class 'nova.exception
Steps to reproduce:
1) Create instance.
$ nova boot --flavor <flavor-id> --image <image-id> <instance-name>
2) To change the instance task_state to anything other than 'None', I tried to resize the instance.
$ nova resize <instance-id> <flavor-id>
3) Try to force-delete instance, just after above step, so that instance task state is anything in (resize_prep, resize_migrating, resize_migrated, resize_finish), but not 'None'.
$ nova force-delete <instance-id>
4) User gets below error on console:
ERROR (ClientException): Unexpected API Error. Please report this at http://
<class 'nova.exception
Actual result:
User gets 500 ClientException Error.
Expected result:
The instance should be deleted without any error.
traceback from nova-api logs:
DEBUG oslo_concurrenc
00s {{(pid=24369) inner /usr/lib/
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
ERROR nova.api.
INFO nova.api.
<class 'nova.exception
DEBUG nova.api.
NOTE: If user tries delete api instead of force-delete api for instance deletion, in that case instance is deleted and no error is thrown.
Changed in nova: | |
assignee: | nobody → Rajesh Tailor (ratailor) |
status: | New → In Progress |
Changed in nova: | |
importance: | Undecided → Medium |
tags: | added: api |
Fix proposed to branch: master /review. openstack. org/530879
Review: https:/