O04三、计算节点宕机了怎么办

 
Rebuild 能够恢复损坏的instance 。那若是是宿主机坏了怎么办呢?好比硬件故障或者断电形成整台计算机节点没法工做,该节点上运行的instance如何恢复呢?
 
用shelve或者Migrate可不能够?很不幸,这两个操做都要求instance 所在的计算节点的 nova-compute服务正常运行。幸运的是,还有 Evacuate
 
Evacuate 可在 nova-compute 没法工做的状况下将节点上的instance 迁移到其余计算节点上,但有个前提:instance的镜像文件必须放在共享存储上
 
咱们能够经过断电模拟计算节点故障,而后执行Evacuate 操做恢复 instance。目前Evacuate只能经过CLI 执行。
 
stack@DevStack-Controller:~$ nova help evacuate
usage: nova evacuate [--password <password>] [--force] <server> [<host>]
 
Evacuate server from failed host.
 
Positional arguments:
  <server>               Name or ID of server.
  <host>                 Name or ID of the target host. If no host is
                         specified, the scheduler will choose one.
 
Optional arguments:
  --password <password>  Set the provided admin password on the evacuated
                         server. Not applicable if the server is on shared
                         storage.
  --force                Force to not verify the scheduler if a host is
                         provided. (Supported by API versions '2.29' -
                         '2.latest')
 
其实 Evacuate 是经过rebuild 操做实现的,由于Evacuate 是用共享存储上的instance的镜像文件从新建立虚机
 
一、先是 nova-scheduler 选择新的计算节点
二、nova-compute 在计算节点上执行rebuild操做
相关文章
相关标签/搜索