Ask Your Question

Revision history [back]

Hello. I`m Newbie.

I met same error message after installed Openstack-newton on Centos 7 (Virtual box 5) according to Openstack tutorial guide for learning and testing. I checked that nova-compute and libvirtd daemon status. Daemons were ran normally. but libvirtd daemon was restarted when i tried to create new instance. So i tried to create new instance manually using libvirtd.

$ cd /var/lib/nova/instances/{failed-instance-uuid}/

$ virsh create ./libvirt.xml

I met 'End of file while reading data: Input/output error' after running virsh. And libvirtd was restarted again.

So i tried to create new instance manually after modify libvirt.xml using virsh. I removed 'mode=host-model' attribute on 'cpu' node in libvirt.xml file. And i retried. Then, it worked.

I don`t know why libvirtd restart by 'mode' attribute. This attribute is valid. (Ref: https://libvirt.org/formatdomain.html#elementsCPU )

So, I modified /usr/lib/python-2.7/site-packages/nova/virt/libvirt/config.py file. I heard this file is domain XML generator of instance configuration. (https://ask.openstack.org/en/question/27156/how-to-customize-libvirtxml-for-an-instance/)

Line 584 in this file,

...

if self.mode is not None:
    cpu.set("mode",self.mode)
cpu.set("match", self.match)

...

I changed to comment upper 2 lines. ('if self.mode is not None: ', 'cpu.set("mode",self.mode)') and I moved to backup directory config.pyo and config.pyc file in /usr/lib/python-2.7/site-packages/nova/virt/libvirt/ directory. finally, I restarted nova-compute daemon. As a result, I can create new instance on dashboard.

I`m sorry for my poor english.

Best regards.