xenserver 恢复从pool中删除的机器状态

来源:互联网 发布:天子网络 编辑:程序博客网 时间:2024/05/12 13:44

I Had the same problem on a Xenserver 6.2 server, and fixed with these steps.
当我用xencenter在host关闭的状态下,将它从池中delete掉,然后重启host机会一值报错,大概是它已经从pool中删除,xe命令运行不成功,通过以下的方法可以恢复

1) on the slave server check the state of the server

xe host-is-in-emergency-modeanswer: true

2) because the server is still in emergency mode, we need to edit the pool.conf.

nano /etc/xensource/pool.conf

Remove all entry and add : master
保存配置

3) I then renamed the state.db with this command.

mv /var/xapi/state.db /var/xapi/state.db_old

Then restart the toolstack:

xe toolstack-restart.

In the Console iInow could use the emergency network reset. configure the Management interface. after reboot of the server i could connect is to XenCenter again.

hope this helps.

4) Thanks it worked. After that your Local SR for DVD Drive and Removable storage (for USB stuffs, or attaching block device directly) will be gone. Which can be recreated using :

# xe sr-create host-uuid=<uuid> content-type=iso name-label=”DVD drives” type=udev device-config:location=/dev/xapi/cd# xe sr-create host-uuid=<uuid> content-type=disk name-label=”Removable storage” type=udev device-config:location=/dev/xapi/block

Try with an first boot activate , it worked for me

总结为下(注意,如果你更换过xenserver机器的ip,最后一步执行完会把host机的ip配置为你初始安装xenserver时的ip)

# /etc/init.d/xapi stop# echo master > /etc/xensource/pool.conf # rm -f /var/xapi/state.db* # rm -f /var/xapi/local.db # /etc/init.d/firstboot activate
0 0
原创粉丝点击