IAAS平台Resize失败故障处理
作者:互联网
背景
上通服IAAS平台某一实例于2022年05月24日resize错误,初步判定为数据库中数据不一致导致resize时检查卷attach状态错误,现将解决方法总结如下:
故障截图
1.根据实例名查找实例ID与卷ID
source admin-openstack.sh
openstack server list --project project_001|grep entrygo-023
openstack server show e1071139-fa71-42ce-ae79-b93914958ee9
2.修改实例状态
处于error状态的实例必须通过修改数据库表修改实例状态。
mysql -uroot -p
use nova;
SELECT * from instances where uuid='e1071139-fa71-42ce-ae79-b93914958ee9'\G
UPDATE instances SET vm_state='active' where uuid='e1071139-fa71-42ce-ae79-b93914958ee9';
SELECT * from instances where uuid='e1071139-fa71-42ce-ae79-b93914958ee9'\G
exit();
3.分离卷
只能分离状态为available的实例。
nova volume-detach e1071139-fa71-42ce-ae79-b93914958ee9 8dd2af95-5006-43b5-a685-2f1e272fc71c
openstack volume list |grep 8dd2af95-5006-43b5-a685-2f1e272fc71c
openstack server stop e1071139-fa71-42ce-ae79-b93914958ee9
4.重新Resize并Confirm
openstack flavor list
nova resize e1071139-fa71-42ce-ae79-b93914958ee9 c0c67d59-3822-4ebb-9076-3c4eea8062a4
nova resize-confirm e1071139-fa71-42ce-ae79-b93914958ee9
openstack server show e1071139-fa71-42ce-ae79-b93914958ee9
5.重新附加卷
nova volume-attach e1071139-fa71-42ce-ae79-b93914958ee9 8dd2af95-5006-43b5-a685-2f1e272fc71c
# nova reboot e1071139-fa71-42ce-ae79-b93914958ee9
然后返回dashboard界面硬重启实例即可
标签:e1071139,b93914958ee9,故障,ae79,openstack,IAAS,42ce,Resize,fa71 来源: https://www.cnblogs.com/wang-hongwei/p/16408733.html