← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1289174] [NEW] resize an instance should not set state to error if no host found

 

Public bug reported:

In resize operation there is code looks like:

if not instance['host']:
    self._set_instance_error_state(context, instance['uuid'])
    msg = _('Instance has no source host')
    raise exception.MigrationError(msg)

same_host = instance['host'] == self.host
if same_host and not CONF.allow_resize_to_same_host:
    self._set_instance_error_state(context, instance['uuid'])
    msg = _('destination same as source!')
    raise exception.MigrationError(msg)

however, it's not reasonable to set an instance to ERROR state if we can't find a host when we try to resize an instance 
we'd better keep the instance in ACTIVE state and report there is no host

** Affects: nova
     Importance: Undecided
     Assignee: jichencom (jichenjc)
         Status: New

** Changed in: nova
     Assignee: (unassigned) => jichencom (jichenjc)

-- 
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/1289174

Title:
  resize an instance should not set state to error if no host found

Status in OpenStack Compute (Nova):
  New

Bug description:
  In resize operation there is code looks like:

  if not instance['host']:
      self._set_instance_error_state(context, instance['uuid'])
      msg = _('Instance has no source host')
      raise exception.MigrationError(msg)

  same_host = instance['host'] == self.host
  if same_host and not CONF.allow_resize_to_same_host:
      self._set_instance_error_state(context, instance['uuid'])
      msg = _('destination same as source!')
      raise exception.MigrationError(msg)

  however, it's not reasonable to set an instance to ERROR state if we can't find a host when we try to resize an instance 
  we'd better keep the instance in ACTIVE state and report there is no host

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1289174/+subscriptions


Follow ups

References