During compute manager startup init_host is called. One of the functions there is to delete instance data that doesn't belong to this host i.e. _destroy_evacuated_instances. But this function only checks if the local instance belongs to the host or not. It doesn't check the task_state.
If at this time a a resize migration is taking place and the destination compute manager is restarted it might destroy the resizing instance.
It was intended to have that fix deal with resize migrating instances as well as those just in the migrating state but as pointed out in a review comment this solution will work for migrating but a fix for resize would require further changes so I have raised this bug to highlight that.
During compute manager startup init_host is called. One of the functions there is to delete instance data that doesn't belong to this host i.e. _destroy_ evacuated_ instances. But this function only checks if the local instance belongs to the host or not. It doesn't check the task_state.
If at this time a a resize migration is taking place and the destination compute manager is restarted it might destroy the resizing instance.
A similar bug concerning just the migrating state is outlined here: https:/ /bugs.launchpad .net/nova/ +bug/1319797 and a fix is proposed here: https:/ /review. openstack. org/#/c/ 93903
It was intended to have that fix deal with resize migrating instances as well as those just in the migrating state but as pointed out in a review comment this solution will work for migrating but a fix for resize would require further changes so I have raised this bug to highlight that.