重庆思庄Oracle、Redhat认证学习论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 3050|回复: 0
打印 上一主题 下一主题

openstack nova-compute 无法启动,报Nova requires QEMU version 2.1.0

[复制链接]
跳转到指定楼层
楼主
发表于 2017-10-31 22:17:44 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
openstack Pike for Centos7.4




环境:
CentOS7.4
openstack pike










错误1:Nova节点无法启动
[root@controller ~]# openstack compute service list
+----+------------------+------------+----------+---------+-------+----------------------------+
| ID | Binary           | Host       | Zone     | Status  | State | Updated At                 |
+----+------------------+------------+----------+---------+-------+----------------------------+
|  1 | nova-consoleauth | controller | internal | enabled | up    | 2017-10-31T11:23:02.000000 |
|  6 | nova-conductor   | controller | internal | enabled | up    | 2017-10-31T11:23:11.000000 |
|  7 | nova-console     | controller | internal | enabled | up    | 2017-10-31T11:23:02.000000 |
|  8 | nova-compute     | controller | nova     | enabled | down  | 2017-10-29T09:39:52.000000 |
|  9 | nova-scheduler   | controller | internal | enabled | up    | 2017-10-31T11:23:12.000000 |
+----+------------------+------------+----------+---------+-------+----------------------------+


察看日志:/var/log/nova/nova-compute,发现以下错误:


ERROR oslo_service.service InternalError: Nova requires QEMU version 2.1.0 or greater

解决:

错误报的很明显,qemu版本必须>=2.1.0,但centos7.4默认的qemu版本为2.0.0,所以必须升级qemu

https://wiki.qemu.org/Hosts/Linux

1.安装

yum -y install gcc gcc-c++ automake libtool bzip2-devel libuuid-devel spice-protocol spice-server-devel usbredir-devel bison flex libaio-devel libcap-devel libiscsi-devel
可选yum -y install git glib2-devel libfdt-devel pixman-devel zlib-devel
wget https://download.qemu.org/qemu-2.10.1.tar.xz
tar xvJf qemu-2.10.1.tar.xz
cd qemu-2.10.1
./configure --enable-usb-redir --enable-libusb --enable-spice --enable-kvm --enable-bzip2 --prefix=/opt/qemu --enable-linux-aio --enable-system --target-list=x86_64-softmmu,x86_64-linux-user
make -j4 && make install
2.备份原始qemu
mv -f /usr/libexec/qemu-kvm{,.bak}
mv -f /usr/bin/qemu-img{,.bak}
mv -f /usr/bin/qemu-io{,.bak}
mv -f /usr/bin/qemu-nbd{,.bak}
3.建软链
ln -s /opt/qemu/bin/qemu-system-x86_64 /usr/libexec/qemu-kvm
ln -s /opt/qemu/bin/qemu-img /usr/bin/
ln -s /opt/qemu/bin/qemu-io /usr/bin/
ln -s /opt/qemu/bin/qemu-nbd /usr/bin/
ln -s /opt/qemu/bin/qemu-system-x86_64 /usr/bin/qemu-system-x86_64
ln -s /opt/qemu/bin/qemu-x86_64 /usr/bin/qemu-x86_64

4.重启nova-compute
systemctl restart openstack-nova-compute

[root@controller bin]# systemctl status openstack-nova-compute
● openstack-nova-compute.service - OpenStack Nova Compute Server
   Loaded: loaded (/usr/lib/systemd/system/openstack-nova-compute.service; enabled; vendor preset: disabled)
   Active: active (running) since Tue 2017-10-31 08:42:23 EDT; 1s ago
Main PID: 63979 (nova-compute)
   CGroup: /system.slice/openstack-nova-compute.service
           └─63979 /usr/bin/python2 /usr/bin/nova-compute
Oct 31 08:42:18 controller systemd[1]: Starting OpenStack Nova Compute Server...
Oct 31 08:42:23 controller systemd[1]: Started OpenStack Nova Compute Server.


[root@controller bin]# openstack compute service list
+----+------------------+------------+----------+---------+-------+----------------------------+
| ID | Binary           | Host       | Zone     | Status  | State | Updated At                 |
+----+------------------+------------+----------+---------+-------+----------------------------+
|  1 | nova-consoleauth | controller | internal | enabled | up    | 2017-10-31T12:43:11.000000 |
|  6 | nova-conductor   | controller | internal | enabled | up    | 2017-10-31T12:43:11.000000 |
|  7 | nova-console     | controller | internal | enabled | up    | 2017-10-31T12:43:02.000000 |
|  8 | nova-compute     | controller | nova     | enabled | up    | 2017-10-31T12:43:07.000000 |
|  9 | nova-scheduler   | controller | internal | enabled | up    | 2017-10-31T12:43:02.000000 |
+----+------------------+------------+----------+---------+-------+----------------------------+

通过以上处理后,问题解决.

分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 支持支持 反对反对
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|手机版|小黑屋|重庆思庄Oracle、Redhat认证学习论坛 ( 渝ICP备12004239号-4 )

GMT+8, 2024-11-24 20:36 , Processed in 0.087437 second(s), 20 queries .

重庆思庄学习中心论坛-重庆思庄科技有限公司论坛

© 2001-2020

快速回复 返回顶部 返回列表