Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
For bugs related to Red Hat Enterprise Linux 5 product line. The current stable release is 5.10. For Red Hat Enterprise Linux 6 and above, please visit Red Hat JIRA https://issues.redhat.com/secure/CreateIssue!default.jspa?pid=12332745 to report new issues.

Bug 454620

Summary: Could not refresh connection xen:/// exceptions.KeyError '00000000-0000-0000-0000-000000000000'
Product: Red Hat Enterprise Linux 5 Reporter: Alexander Todorov <atodorov>
Component: virt-managerAssignee: Cole Robinson <crobinso>
Status: CLOSED WORKSFORME QA Contact: Virtualization Bugs <virt-bugs>
Severity: low Docs Contact:
Priority: low    
Version: 5.2CC: xen-maint
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-01-23 15:59:22 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
virt-manager.log with the 2 error messages none

Description Alexander Todorov 2008-07-09 12:55:07 UTC
Description of problem:
That's the error in the logs after a series of 2 errors. I'll try to describe
them in details in steps to reproduce as I can't summarize what is wrong.

Version-Release number of selected component (if applicable):
virt-manager-0.5.3-8.el5
xen-3.0.3-64.el5


How reproducible:
100%

Steps to Reproduce:
1. Install F9, PV, i386, guest with encrypted FS (the whole disk)
2. Boot into the guest (name f1 in my case)
3. From virt-manager open the graphical console and observe the guest
4. When asked for the LUKS password enter a wrong password 3 times
5. There's a traceback in the guest
6. From the UI select: Virtual machine -> Destroy to destroy the guest & confirm
7. Error message #1 occurs in the logs (see below)
8. Close virt-manager
9. Start virt-manager again
10. Try to connect to the local xen connection
11. Error message #2 occurs in the logs (see below)

Actual results:
4-5) is described in https://bugzilla.redhat.com/show_bug.cgi?id=446669#c12 and
https://bugzilla.redhat.com/show_bug.cgi?id=446669#c13 and has nothing to do
with this bug. It merely produces a guest which doesn't want to shutdown so I
used destroy. 

7) After guest is destroyed th log starts filling up quickly with messages:

[Wed, 09 Jul 2008 07:55:50 virt-manager 4596] ERROR (engine:156) Could not
refresh connection xen:///
libvirt.libvirtError virDomainLookupByID() failed internal error domain
information incomplete, missing name
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/engine.py", line 152, in _tick
    self.connections[uri]["connection"].tick()
  File "/usr/share/virt-manager/virtManager/connection.py", line 555, in tick
    vm = self.vmm.lookupByID(id)
  File "/usr/lib/python2.4/site-packages/libvirt.py", line 638, in lookupByID
    if ret is None:raise libvirtError('virDomainLookupByID() failed', conn=self)
libvirtError: virDomainLookupByID() failed internal error domain information
incomplete, missing name


10) After clicking on the local connection the first messages in the log are:

[Wed, 09 Jul 2008 07:56:55 virt-manager 5939] INFO (virt-manager:126)
Application startup
[Wed, 09 Jul 2008 07:56:55 virt-manager 5940] DEBUG (engine:74) About to connect
to uris ['xen:///']
[Wed, 09 Jul 2008 07:57:09 virt-manager 5940] DEBUG (connection:293) Scheduling
background open thread for xen:///
[Wed, 09 Jul 2008 07:57:09 virt-manager 5940] DEBUG (connection:300) Background
thread is running
[Wed, 09 Jul 2008 07:57:09 virt-manager 5940] DEBUG (connection:329) Background
open thread complete, scheduling notify
[Wed, 09 Jul 2008 07:57:09 virt-manager 5940] DEBUG (connection:338) Notifying
open result
[Wed, 09 Jul 2008 07:57:09 virt-manager 5940] ERROR (virt-manager:132) Traceback
(most recent call last):
  File "/usr/share/virt-manager/virtManager/connection.py", line 342, in
_open_notify
    self.tick()
  File "/usr/share/virt-manager/virtManager/connection.py", line 555, in tick
    vm = self.vmm.lookupByID(id)
  File "/usr/lib/python2.4/site-packages/libvirt.py", line 638, in lookupByID
    if ret is None:raise libvirtError('virDomainLookupByID() failed', conn=self)
libvirtError: virDomainLookupByID() failed internal error domain information
incomplete, missing name
None
[Wed, 09 Jul 2008 07:57:10 virt-manager 5940] ERROR (engine:156) Could not
refresh connection xen:///
exceptions.KeyError '00000000-0000-0000-0000-000000000000'
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/engine.py", line 152, in _tick
    self.connections[uri]["connection"].tick()
  File "/usr/share/virt-manager/virtManager/connection.py", line 518, in tick
    vm = self.vms[uuid]
KeyError: '00000000-0000-0000-0000-000000000000'


After that the last message (KeyError:00000) starts repeating.

Expected results:
Failed guest is destroyed and then it is able to start it again.

Additional info:
Restarting xend doesn't seem to help, only machine reboot helps to get
virt-manager running again.

Comment 1 Alexander Todorov 2008-07-09 12:55:07 UTC
Created attachment 311369 [details]
virt-manager.log with the 2 error messages

Comment 2 Alexander Todorov 2008-07-09 12:56:17 UTC
Please advise if the 2 error messages are related to each other or they need
separate bugs.

Thanks!

Comment 3 RHEL Program Management 2008-07-09 12:59:29 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 5 Cole Robinson 2009-01-22 17:17:59 UTC
Okay, the gist here is that something in the xen/libvirt arena is out of whack after you destroy the guest (that is the 'internal error domain information
incomplete, missing name' error). As a result, we get cascading errors from virt-manager which aren't the root issue (that's the KeyError 000... part).

Alexander, can you still reproduce this on rhel 5.3? If so, can you post:

virsh dumpxml vmname
xm list --long vmname

Both before the failure and after the failure? If you can't reproduce, my assumption is that the underlying bug was fixed for 5.3 and we should close this.

Comment 6 Alexander Todorov 2009-01-23 13:54:00 UTC
Could not reproduce on fresh 5.3 install with xen-3.0.3-80.el5, virt-manager-0.5.3-10.el5.

Comment 7 Cole Robinson 2009-01-23 15:59:22 UTC
Thanks, closing this as WORKSFORME.