Public bug reported:
Description
===========
When an instance task state is RESIZE_MIGRATED or RESIZE_FINISH, delete the
instance will hint an error,
I found some problems with the code, because my flavor contains vram, a
TypeError Thrown out.
Steps to reproduce
==================
1.create an instance use flavor1,names server1
2.resize it but not resize confirm.
3.delete the instance quickly.
4.you can run " nova resize service1 flavor2 && sleep 2.0 && nova delete
server1 ".
Just delete the instance quickly
When resize an instance, its task state will go through None =>
resize_migrating => resize_migrated => resize_finish => None, the
purpose of sleep is to catch the target state,resize_migrated or
resize_finish.
Environment
===========
RDO Newton
Logs & Configs
==============
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/nova/api/openstack/extensions.py",
line 338, in wrapped
return f(*args, **kwargs)
File
"/usr/lib/python2.7/site-packages/nova/api/openstack/compute/servers.py", line
914, in delete
self._delete(req.environ['nova.context'], req, id)
File
"/usr/lib/python2.7/site-packages/nova/api/openstack/compute/servers.py", line
768, in _delete
self.compute_api.delete(context, instance)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 166, in
inner
return function(self, context, instance, *args, **kwargs)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 173, in
_wrapped
return fn(self, context, instance, *args, **kwargs)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 147, in
inner
return f(self, context, instance, *args, **kw)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 2048, in
delete
self._delete_instance(context, instance)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 2039, in
_delete_instance
task_state=task_states.DELETING)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 1815, in
_delete
quotas.rollback()
File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 220, in
__exit__
self.force_reraise()
File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 196, in
force_reraise
six.reraise(self.type_, self.value, self.tb)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 1735, in
_delete
project_id, user_id)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 1878, in
_create_reservations
instance_memory_mb = old_flavor.memory_mb + vram_mb
TypeError: unsupported operand type(s) for +: 'int' and 'unicode'
** 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/1689289
Title:
can not delete an instance when resizing
Status in OpenStack Compute (nova):
New
Bug description:
Description
===========
When an instance task state is RESIZE_MIGRATED or RESIZE_FINISH, delete the
instance will hint an error,
I found some problems with the code, because my flavor contains vram, a
TypeError Thrown out.
Steps to reproduce
==================
1.create an instance use flavor1,names server1
2.resize it but not resize confirm.
3.delete the instance quickly.
4.you can run " nova resize service1 flavor2 && sleep 2.0 && nova delete
server1 ".
Just delete the instance quickly
When resize an instance, its task state will go through None =>
resize_migrating => resize_migrated => resize_finish => None, the
purpose of sleep is to catch the target state,resize_migrated or
resize_finish.
Environment
===========
RDO Newton
Logs & Configs
==============
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/nova/api/openstack/extensions.py",
line 338, in wrapped
return f(*args, **kwargs)
File
"/usr/lib/python2.7/site-packages/nova/api/openstack/compute/servers.py", line
914, in delete
self._delete(req.environ['nova.context'], req, id)
File
"/usr/lib/python2.7/site-packages/nova/api/openstack/compute/servers.py", line
768, in _delete
self.compute_api.delete(context, instance)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 166, in
inner
return function(self, context, instance, *args, **kwargs)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 173, in
_wrapped
return fn(self, context, instance, *args, **kwargs)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 147, in
inner
return f(self, context, instance, *args, **kw)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 2048, in
delete
self._delete_instance(context, instance)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 2039, in
_delete_instance
task_state=task_states.DELETING)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 1815, in
_delete
quotas.rollback()
File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 220,
in __exit__
self.force_reraise()
File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 196,
in force_reraise
six.reraise(self.type_, self.value, self.tb)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 1735, in
_delete
project_id, user_id)
File "/usr/lib/python2.7/site-packages/nova/compute/api.py", line 1878, in
_create_reservations
instance_memory_mb = old_flavor.memory_mb + vram_mb
TypeError: unsupported operand type(s) for +: 'int' and 'unicode'
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1689289/+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