The REST API handler code checks this, I just missed that since I was expecting to find it in the nova.compute.api.API.evacuate method:
https://github.com/openstack/nova/blob/2a4ca8bd6aa40ccd26300feaef4267aa71f69abf/nova/api/openstack/compute/evacuate.py#L114 ** Changed in: nova Status: Confirmed => Invalid -- 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/1714235 Title: evacuate API does not restrict one from trying to evacuate to the source host Status in OpenStack Compute (nova): Invalid Bug description: This is purely based on code inspection, but the compute API method 'evacuate' does not check if the specified host (if there was one) is different from instance.host. It checks if the service is up on that host, which could be down and you can still specify the instance.host. Eventually the compute API will RPC cast to conductor task manager which will fail with an RPC error trying to RPC cast to the ComputeManager.rebuild_instance method on the compute service, which is down. The bug here is that instead of getting an obvious 400 error from the API, you're left with not much for details when it fails. There should be an instance action and finish event, but only the admin can see the traceback in the event. Also, the instance.task_state would be left in 'rebuilding' state, and would require it to be reset to use the instance again. To manage notifications about this bug go to: https://bugs.launchpad.net/nova/+bug/1714235/+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

