Ask Your Question

[Libvirt] VM does not boot in Ocata (libvirt.xml missing, wrong owner for console.log)

asked 2017-03-02 13:09:35 -0500

Herr-Herner gravatar image

updated 2017-03-03 03:48:08 -0500

I am setting up OpenStack Ocata as HA deployment on Ubuntu 16.04. and I am confronted with a heavy blocker. I have set up Keystone, Glance, Nova, Neutron and Horizon. I am able to create and spawn a VM, but it does not boot.

The block device is created and available in my Ceph cluster. Libvirt gives me only:

Mar 2 17:09:11 os-compute01 virtlogd[3218]: End of file while reading data: Input/output error

The instances folder located under /var/lib/nova/instances contains a folder for the VM, but it contains only the empty file console.log and NO libvirt.xml. Another strange thing is that console.log is owned by root:root. Under Newton the file is owned by libvirt-qemu:kvm. The user libvirt-qemu is not able to write to that file.

I have tried to correct the ownership manaully and copied the VM specification file from "/etc/libvirt/qemu/instance-*.xml" to /var/lib/nova/instancs/[VM-UUID]/libvirt.xml. After rebooting the VM the console.log is owned by root:root again and the VM does not boot, maybe the file is just removed and recreated.

There seems to be problem in the current Ocata release of Nova.

Any hints how to workaround or fix the problem?

Thank you very much!

This is my nova.conf on os-compute01:

compute_monitors = cpu.virt_driver
debug = true
firewall_driver = nova.virt.firewall.NoopFirewallDriver
host = os-compute01
instance_usage_audit = true
instance_usage_audit_period = hour
notify_on_state_change = vm_and_task_state
instances_path = $state_path/instances
linuxnet_interface_driver =
log_dir = /var/log/nova
memcached_servers = os-memcache:11211
my_ip =
notification_driver = messagingv2
resume_guests_state_on_host_boot = true
state_path = /var/lib/nova
transport_url = rabbit://nova:SECRET@os-rabbit01:5672,nova:SECRET@os-rabbit02:5672/openstack
use_neutron = true

auth_strategy = keystone

enabled = true
backend = oslo_cache.memcache_pool
memcache_servers = os-memcache:11211

catalog_info = volumev2:cinderv2:internalURL

use_local = false

api_servers = http://os-image:9292

auth_type = password
auth_uri = http://os-identity:5000
auth_url = http://os-identity:35357
memcached_servers = os-memcache:11211
password = SECRET
project_domain_name = default
project_name = service
service_token_roles_required = true
user_domain_name = default
username = nova

auth_type = password
auth_uri = http://os-identity:5000
auth_url = http://os-identity:35357
password = SECRET
project_domain_name = default
project_name = service
region_name = RegionOne
url = http://os-network:9696
user_domain_name = default
username = neutron

lock_path = /var/lock/nova

amqp_durable_queues = true
rabbit_ha_queues = true
rabbit_retry_backoff = 2
rabbit_retry_interval = 1

auth_type = password
auth_uri = http://os-identity:5000
auth_url = http://os-identity:35357
username = placement
password = SECRET
user_domain_name = default
project_name = service
project_domain_name = default
os_interface = internal
os_region_name = RegionOne

enabled = true
novncproxy_base_url =
vncserver_listen =
vncserver_proxyclient_address = $my_ip

and my nova-compute.conf:

compute_driver = libvirt.LibvirtDriver

cpu_mode = custom
cpu_model = SandyBridge
hw_disk_discard = unmap
images_rbd_ceph_conf = /etc/ceph/ceph.conf
images_rbd_pool = vms
images_type = rbd
inject_key = false
inject_partition = -2
inject_password = false
rbd_secret_uuid = SECRET
rbd_user = cinder
virt_type = kvm
edit retag flag offensive close merge delete


Have something similar with ubuntu ocata and libvirt 2.5. Libvirt group was changed to from libvirtd to libvirt, but still don't know how to fix that. If find a solution, please share it

Eduardo Gonzalez gravatar imageEduardo Gonzalez ( 2017-03-02 16:03:06 -0500 )edit

I solved the issue by adding libvirt.hw_machine_type = "x86_64=pc-i440fx-xenial,i686=pc-i440fx-xenial" to my nova-compute.conf.

Herr-Herner gravatar imageHerr-Herner ( 2017-03-06 08:27:17 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2017-03-03 03:45:24 -0500

Herr-Herner gravatar image

updated 2017-03-06 05:00:02 -0500

There is another strange thing. I am on Ubuntu 16.04.

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.2 LTS
Release: 16.04
Codename: xenial

When I create a VM a corresponding xml file gets created in /etc/libvirt/qemu/instance-[id].xml:

OVERWRITTEN AND LOST. Changes to this xml configuration should be made using:
  virsh edit instance-0000003c
or other application using the libvirt API.

<domain type='kvm'>
    <nova:instance xmlns:nova="">
      <nova:package version="15.0.0"/>
      <nova:creationTime>2017-03-03 08:58:02</nova:creationTime>
      <nova:flavor name="mat.medium">
        <nova:user uuid="17aafbe8a8754c2a8e4de9dc1f0643dc">admin</nova:user>
        <nova:project uuid="53eed6212bd54ff5acc4ad110e9899ac">demo</nova:project>
      <nova:root type="image" uuid="6112eee2-4bbb-450d-b132-e8b0fdaf03f2"/>
  <memory unit='KiB'>4194304</memory>
  <currentMemory unit='KiB'>4194304</currentMemory>
  <vcpu placement='static'>1</vcpu>
  <sysinfo type='smbios'>
      <entry name='manufacturer'>OpenStack Foundation</entry>
      <entry name='product'>OpenStack Nova</entry>
      <entry name='version'>15.0.0</entry>
      <entry name='serial'>3b3fc34f-f5f8-6258-950b-284758b6d5ce</entry>
      <entry name='uuid'>7151c8b7-1ea5-4701-bb79-b482d9e253b8</entry>
      <entry name='family'>Virtual Machine</entry>
    <type arch='x86_64' machine='pc-i440fx-zesty'>hvm</type>
    <boot dev='hd'/>
    <smbios mode='sysinfo'/>
  <cpu mode='custom' match='exact'>
    <model fallback='allow'>SandyBridge</model>
    <topology sockets='1' cores='1' threads='1'/>
  <clock offset='utc'>
    <timer name='pit' tickpolicy='delay'/>
    <timer name='rtc' tickpolicy='catchup'/>
    <timer name='hpet' present='no'/>
    <disk type='network' device='disk'>
      <driver name='qemu' type='raw' cache='writeback' discard='unmap'/>
      <auth username='cinder'>
        <secret type='ceph' uuid='e5479084-e43e-4a1e-959a-b9989f02e632'/>
      <source protocol='rbd' name='vms/7151c8b7-1ea5-4701-bb79-b482d9e253b8_disk'>
        <host name='' port='6789'/>
        <host name='' port='6789'/>
        <host name='' port='6789'/>
      <target dev='sda' bus='scsi'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    <controller type='scsi' index='0' model='virtio-scsi'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    <controller type='usb' index='0' model='piix3-uhci'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
    <controller type='pci' index='0' model='pci-root'/>
    <interface type='bridge'>
      <mac address='02:05:69:29:af:e1'/>
      <source bridge='qbr5663b508-00'/>
      <target dev='tap5663b508-00'/>
      <model type='virtio'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
    <serial type='pty'>
      <log file='/var/lib/nova/instances/7151c8b7-1ea5-4701-bb79-b482d9e253b8/console.log' append='off'/>
      <target port='0'/>
    <console type='pty'>
      <log file='/var/lib/nova/instances/7151c8b7-1ea5-4701-bb79-b482d9e253b8/console.log' append='off'/>
      <target type='serial ...
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2017-03-02 13:09:35 -0500

Seen: 980 times

Last updated: Mar 06 '17