Openstack Compute with Xen in Ubuntu 11.10 fails to load due to Domain-0 being considered an instance

Bug #912701 reported by Rogério Vinhal Nunes
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Undecided
Alvaro Lopez
nova (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

I've installed nova-compute along with xen and libvirt in a fresh Ubuntu 11.10 install. But I'm experiencing some problems to get it running.

nova-compute service fails to start and nova-compute.log shows this error message:

2011-12-26 09:36:03,679 CRITICAL nova [-] [Errno 2] No such file or directory: '/var/lib/nova/instances/Domain-0/console.ring'
(nova): TRACE: Traceback (most recent call last):
(nova): TRACE: File "/usr/bin/nova-compute", line 49, in <module>
(nova): TRACE: service.wait()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/service.py", line 357, in wait
(nova): TRACE: _launcher.wait()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/service.py", line 107, in wait
(nova): TRACE: service.wait()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/eventlet/greenthread.py", line 166, in wait
(nova): TRACE: return self._exit_event.wait()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/eventlet/event.py", line 116, in wait
(nova): TRACE: return hubs.get_hub().switch()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/eventlet/hubs/hub.py", line 177, in switch
(nova): TRACE: return self.greenlet.switch()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/eventlet/greenthread.py", line 192, in main
(nova): TRACE: result = function(*args, **kwargs)
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/service.py", line 77, in run_server
(nova): TRACE: server.start()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/service.py", line 137, in start
(nova): TRACE: self.manager.init_host()
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/compute/manager.py", line 157, in init_host
(nova): TRACE: self.driver.init_host(host=self.host)
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/virt/libvirt/connection.py", line 253, in init_host
(nova): TRACE: self._start_console_logger(name, fifo_path, ringbuffer_path)
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/virt/libvirt/connection.py", line 297, in _start_console_logger
(nova): TRACE: self.console_loggers[name] = ConsoleLogger(fifo_path, ringbuffer_path)
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/virt/libvirt/connection.py", line 186, in __init__
(nova): TRACE: FLAGS.libvirt_console_log_size)
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/utils.py", line 932, in __init__
(nova): TRACE: self.f = self._open(backing_file)
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/utils.py", line 970, in _open
(nova): TRACE: fd = os.open(filename, os.O_RDWR | os.O_CREAT, 0666)
(nova): TRACE: OSError: [Errno 2] No such file or directory: '/var/lib/nova/instances/Domain-0/console.ring'

Is there anything else I need to do to make Diablo work with Xen? It seems that openstack is considering Domain-0 an instance, what shouldn't be happening. I used to have a similar configuration in Ubuntu 10.04 and it worked fine, but I found out later that in my working confoguration the command "virsh list" doesn't show Domain-0, and in the new one it does, so this problem may be related to openstack-nova getting the libvirt output and considering Domain-0 an instance.

Dave Walker (davewalker)
Changed in nova (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in nova (Ubuntu):
status: New → Confirmed
Alvaro Lopez (aloga)
Changed in nova:
status: New → Confirmed
Alvaro Lopez (aloga)
Changed in nova:
assignee: nobody → Alvaro Lopez (aloga)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master
Review: https://review.openstack.org/3067

Revision history for this message
Mark McLoughlin (markmc) wrote :

Note: this specific issue won't be seen upstream because the console ringbuffer stuff is only in Ubuntu

The fix proposed by Alvaro does make sense upstream even without the ringbuffer stuff, though

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/3067
Committed: http://github.com/openstack/nova/commit/0c2eb242580caff24dc95a9e2b3092cf0b04e958
Submitter: Jenkins
Branch: master

commit 0c2eb242580caff24dc95a9e2b3092cf0b04e958
Author: Alvaro Lopez Garcia <email address hidden>
Date: Mon Jan 16 17:12:35 2012 +0100

    Fixed bug 912701

    Add an check to the list_instances method so that the domains whose ID
    is 0 are not listed, since this is reserved in libvirt for hypervisors.

    Refers to https://lists.launchpad.net/openstack/msg06699.html

    Change-Id: I55f6f370cbaf8bd2254e08afad8b36d833726817

Changed in nova:
status: In Progress → Fix Committed
Revision history for this message
Chuck Short (zulcss) wrote :

This is fixed in precise.

Changed in nova (Ubuntu):
status: Confirmed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: none → essex-4
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: essex-4 → 2012.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.