Move All Instances From Hypervisor in Case of Hardware Failure
Problem
In case of hardware failure for a hypervisor, the instances need to be moved off the host.
Environment
Platform9 Managed OpenStack - All Versions
Nova
Shared storage ( mandatory)
Procedure
Warning: this method should not be used if the host still has instances up and running. This will also fail if the compute service on the host is running.
To find a host for the evacuated instances, list all hosts.
$ openstack host listEvacuate all instances from
FAILED_HOSTtoTARGET_HOST.
$ nova host-evacuate --target_host TARGET_HOST FAILED_HOSTNote: The option --target_host is optional and can be omitted to let the scheduler decide where to place the instances.
Additional Information
The argument
FAILED_HOSTcan also be a pattern to search for instead of an exact hypervisor hostname but it is recommended to use a fully qualified domain name to make sure no hypervisor host is getting evacuated by mistake. As long as you are not using a pattern you might want to use the--strictflag.
Last updated
