当虚机系统不能启动时(前提是系统盘保存在rbd,而不是cinder中),在openstack环境的修复办法(建议在修复前先给虚机打个镜像)数据库
一、使用nova rescue <server> 会从虚机初始镜像启动实例,将实例的原有磁盘会作为second硬盘
二、启动后将第二硬盘联机就能够修复了。
三、修复系统完成后,须要将虚机从rescue恢复到正常模式。windows
尽可能在测试环境使用nova rescue命令,本人就遇到了windows机器在unrescue后出现boot分区文件设置问题致使不能启动的状况。ide
当unrescue后提示不能启动时,须要从新进入unrescue模式,给boot分区增长盘符,并使用bcdedit命令将boot分区的3个参数修改一下:
(e:\为隐藏的100M分区)测试
bcdedit /store e:\boot\bcd /set {bootmgr} device partition=c:
bcdedit /store e:\boot\bcd /set {default} device partition=c:
bcdedit /store e:\boot\bcd /set {default} osdevice partition=c:server
修改完成后再 unrescue 就能够恢复了。blog