Ask Your Question
0

During the deployment the libvirt close connation with nova-compute. libvirtError: End of file while reading data: Input/output error\n' [closed]

asked 2017-01-31 17:13:38 -0500

rodrigocleme gravatar image

updated 2017-02-01 03:37:10 -0500

dbaxps gravatar image

I don't think that it's an authentication because the nova-compute can make the inventory on compute node.

2017-01-31 15:26:47.919 1069 ERROR root [req-27c93056-721f-4e2f-8255-d1ca84e0a562 697777bc8c7643339b4d7bb8690f9304 e22dc96974c94441a747ee3f851a7f3f - - -] Original exception being dropped: ['Traceback (most recent call last):\n', '  File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/guest.py", line 139, in launch\n    return self._domain.createWithFlags(flags)\n', '  File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 186, in doit\n    result = proxy_call(self._autowrap, f, *args, **kwargs)\n', '  File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 144, in proxy_call\n    rv = execute(f, *args, **kwargs)\n', '  File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 125, in execute\n    six.reraise(c, e, tb)\n', '  File "/usr/lib/python2.7/site-packages/eventlet/tpool.py", line 83, in tworker\n    rv = meth(*args, **kwargs)\n', '  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 1065, in createWithFlags\n    if ret == -1: raise libvirtError (\'virDomainCreateWithFlags() failed\', dom=self)\n', 'libvirtError: End of file while reading data: Input/output error\n']
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [req-27c93056-721f-4e2f-8255-d1ca84e0a562 697777bc8c7643339b4d7bb8690f9304 e22dc96974c94441a747ee3f851a7f3f - - -] [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401] Instance failed to spawn
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401] Traceback (most recent call last):
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]   File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2078, in _build_resources
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]     yield resources
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]   File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 1920, in _build_and_run_instance
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]     block_device_info=block_device_info)
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 2596, in spawn
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]     post_xml_callback=gen_confdrive)
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 4836, in _create_domain_and_network
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]     post_xml_callback=post_xml_callback)
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/driver.py", line 4765, in _create_domain
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]     guest.launch(pause=pause)
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/guest.py", line 144, in launch
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]     self._encoded_xml, errors='ignore')
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401]   File "/usr/lib/python2.7/site-packages/nova/virt/libvirt/guest.py", line 111, in _encoded_xml
2017-01-31 15:26:47.920 1069 ERROR nova.compute.manager [instance: 8252d6de-4ecc-4900-baad-be0daf5f9401 ...
(more)
edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by rodrigocleme
close date 2017-02-10 07:26:21.628049

Comments

Does it happen all the time? Are you able to launch any instance? What is your configuration?

There seem to be many possible causes for this error, including config errors (e.g. https://bugs.launchpad.net/nova/+bug/...).

Bernd Bausch gravatar imageBernd Bausch ( 2017-02-02 23:17:52 -0500 )edit

looks like that there is an issue on libvirt 2.0 with Mitaka and Newton, the ticket is telling to downgrade the libvirt to 1.7 same version of Liberyt. Any idea about how can be done the downgrade ? https://bugs.launchpad.net/nova/+bug/1649527 (https://bugs.launchpad.net/nova/+bug/...)

rodrigocleme gravatar imagerodrigocleme ( 2017-02-04 12:23:34 -0500 )edit

2 answers

Sort by ยป oldest newest most voted
1

answered 2017-02-05 14:01:37 -0500

newbiesimon gravatar image

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 (https://libvirt.org/formatdomain.html...) )

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/ (https://ask.openstack.org/en/question...))

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.

edit flag offensive delete link more

Comments

Hi Newbie,

I tried two thing firts the solution that you gave and applying the libvirt patch, both worked fine.

rodrigocleme gravatar imagerodrigocleme ( 2017-02-10 07:25:38 -0500 )edit

there is a option in nova.conf

cpu_mode = none

fixes the issue. Just to avoid people tricking the code base.

Eduardo Gonzalez gravatar imageEduardo Gonzalez ( 2017-02-28 03:10:17 -0500 )edit
0

answered 2017-02-03 13:29:20 -0500

rodrigocleme gravatar image

updated 2017-02-10 07:25:51 -0500

This topic can be closed as resolved. Thank you

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2017-01-31 17:13:38 -0500

Seen: 1,236 times

Last updated: Feb 10 '17