Bug 436320 - Traceback in in retry_login / virt-manager
Traceback in in retry_login / virt-manager
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: virt-manager (Show other bugs)
5.2
All Linux
low Severity low
: rc
: ---
Assigned To: Cole Robinson
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-03-06 09:50 EST by Alexander Todorov
Modified: 2010-03-30 04:50 EDT (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-03-30 04:50:46 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
virt-manager.log (9.19 KB, text/plain)
2008-03-06 09:51 EST, Alexander Todorov
no flags Details
Catch libvirt errors when trying to connect to VNC (917 bytes, text/plain)
2009-12-15 14:25 EST, Cole Robinson
no flags Details

  None (edit)
Description Alexander Todorov 2008-03-06 09:50:56 EST
Description of problem:
After shutting down a xen guest there is a traceback. Please read below for more
details

Version-Release number of selected component (if applicable):
virt-manager-0.5.3-2.el5

How reproducible:
Often but not very consistent

Steps to Reproduce:
1. On a clean system (e.g. no other guests, no image files) run virt-manager
--no-fork
2. Using the GUI create a new pv guest. Use default settings.
3. Proceed with the installation to stage2 in anaconda
4. Once you see the welcome screen wait for 10 secs (may not be related)
5. Press the shutdown button in the virt-viewer GUI
6. The guest shuts down
7. Using the GUI delete the guest from the list
8. Repeat step 2) using the same settings (name, file, network)
9. Repeat steps 3-6
10. There is a traceback on the console.


Actual results:
Traceback

Expected results:
No tracebacks

Additional info:
* I believe the root of the problem is that when the guest is going down
virt-manager will try to reboot it afterwards. While trying to reconnect to the
VNC console it fails. Uploading logs shortly.
Comment 1 Alexander Todorov 2008-03-06 09:51:43 EST
Created attachment 297054 [details]
virt-manager.log

The traceback here is

libvir: Xen Daemon error : internal error domain information incomplete,
missing id
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/console.py", line 391, in
retry_login
    self.try_login()
  File "/usr/share/virt-manager/virtManager/console.py", line 436, in try_login

    protocol, host, port, trans = self.vm.get_graphics_console()
  File "/usr/share/virt-manager/virtManager/domain.py", line 452, in
get_graphics_console
    type = self.get_xml_string("/domain/devices/graphics/@type")
  File "/usr/share/virt-manager/virtManager/domain.py", line 421, in
get_xml_string
    xml = self.get_xml()
  File "/usr/share/virt-manager/virtManager/domain.py", line 53, in get_xml
    self.xml = self.vm.XMLDesc(0)
  File "/usr/lib64/python2.4/site-packages/libvirt.py", line 196, in XMLDesc
    if ret is None: raise libvirtError ('virDomainGetXMLDesc() failed',
dom=self)
libvirt.libvirtError: virDomainGetXMLDesc() failed internal error domain
information incomplete, missing id
Comment 2 Alexander Todorov 2008-03-06 09:55:27 EST
Another traceback which i srelated to the same function is:

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/console.py", line 391, in retry_login
    self.try_login()
  File "/usr/share/virt-manager/virtManager/console.py", line 429, in try_login
    if self.vm.get_id() < 0:
  File "/usr/share/virt-manager/virtManager/domain.py", line 83, in get_id
    return self.vm.ID()
AttributeError: 'NoneType' object has no attribute 'ID'


That comes from the inconsistent reproduction:
1. Follow steps 1-7
2. After the guest is deleted from the list click with the mouse on the line
saying "localhost" so you can get the New button enabled.
3. This traceback appers on the console.
4. Follow steps 8-10 to create the guest again
5. Shortly after stage1 begins virt-manager segfaults
6. Run virt-manager again and reconnect to the VNC console
7. When Shutdown is pressed I hit the first traceback again
Comment 3 Daniel Berrange 2008-03-27 19:51:11 EDT
Are you seeing an actual functionality failure, or is this merely a desire to
get rid of the tracebacks ? Many of the tracebacks are harmless warning due to
domains changing state while virt-mnager is in the middle of querying the state.
If there is actual functionality broken then this needs to be dealt with as a
higher priority.
Comment 4 Alexander Todorov 2008-03-28 05:53:51 EDT
Daniel,
IIRC the GUI console was not able to reconnect after the traceback and wrt
comment #2 virt-manager segfaults. I'll have to do more testing to identify what
is the impact on the end user as this issue is hard to reproduce consistently
and may have been fixed(not happening) in the mean time.
Comment 5 Alexander Todorov 2008-03-28 09:47:36 EDT
Daniel,
I think it is safe to ignore comment #4. I tried several times to reproduce the
issue with RHEL5.2 snap#3. I am seeing the traceback but as you pointed out it
is harmless. I wasn't able to cause virt-manager to segfault as it's been
happening before (probably due to other bugs which were present). 

Can we use this bug to get rid of the tracebacks in the log and replace them
with more user friendly messages like:
WARNING: quering guest $ID for $PROPERTY/$STATE - failed, retrying shortly...
Comment 6 Bill Burns 2008-04-01 11:10:19 EDT
clearing the locker flag. Moving to 5.3.
Comment 7 RHEL Product and Program Management 2008-06-02 16:15:29 EDT
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 9 Cole Robinson 2009-03-08 15:50:35 EDT
I actually just fixed this upstream:

http://hg.et.redhat.com/cgi-bin/hg-virt.cgi/applications/virt-manager--devel/rev/c523ecf75a3e

It is a harmless error (though it will add deceiving tracebacks in the logfile), but the fix is pretty simple, so doesn't hurt to pull in for 5.4
Comment 10 Cole Robinson 2009-03-23 15:35:07 EDT
Should be fixed in virt-manager-0.6.1-1.el5. Setting to MODIFIED.
Comment 12 Mark Xie 2009-07-15 04:13:14 EDT
Fallow the steps the bug given,
1. On a clean system (e.g. no other guests, no image files) run virt-manager
--no-fork
2. Using the GUI create a new pv guest. Use default settings.
3. Proceed with the installation to stage2 in anaconda(I've used local httpd service to provide the ks.cfg file.)
4. Once you see the welcome screen wait for 10 secs (may not be related)
5. Press the shutdown button in the virt-viewer GUI
6. The guest shuts down
7. Using the GUI delete the guest from the list
8. Repeat step 1-7 using the same settings (name, file, network)
9. This traceback appers on the console.

Here I've got some trace messages:

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/details.py", line 1149, in retry_login
    self.try_login()
  File "/usr/share/virt-manager/virtManager/details.py", line 1205, in try_login
    protocol, host, port, trans, username = self.vm.get_graphics_console()
  File "/usr/share/virt-manager/virtManager/domain.py", line 674, in get_graphics_console
    self.update_xml()
  File "/usr/share/virt-manager/virtManager/domain.py", line 97, in update_xml
    self._xml = self.vm.XMLDesc(flags)
  File "/usr/lib64/python2.4/site-packages/libvirt.py", line 231, in XMLDesc
    if ret is None: raise libvirtError ('virDomainGetXMLDesc() failed', dom=self)
libvirt.libvirtError: failed Xen syscall xenDaemonDomainFetch failed to find this domain
When I fallow these steps, again and again, the same traceback message will appear again and again. 


My OS is RHEL5.4 Server X86_64 (20090701.0), detailed version info:
xen-3.0.3-88.el5
xen-devel-3.0.3-88.el5
xen-libs-3.0.3-88.el5
kernel-xen-devel-2.6.18-156.el5
xen-libs-3.0.3-88.el5
kmod-gnbd-xen-0.1.5-2.el5
kmod-gfs-xen-0.1.33-2.el5
kernel-xen-2.6.18-156.el5
virt-manager-debuginfo-0.6.1-6.el5
virt-manager-0.6.1-6.el5
libvirt-debuginfo-0.6.3-14.el5
libvirt-devel-0.6.3-14.el5
libvirt-cim-0.5.5-2.el5
libvirt-0.6.3-14.el5
libvirt-devel-0.6.3-14.el5
libvirt-python-0.6.3-14.el5
libvirt-0.6.3-14.el5
libvirt-debuginfo-0.6.3-14.el5
Comment 13 Cole Robinson 2009-07-27 13:20:45 EDT
Sounds like this bug failed QA. I think this is a separate traceback, but it's the same result as the reported bug.

Setting to ASSIGNED. This should be delayed till 5.5 though since this is only a cosmetic bug.
Comment 15 Cole Robinson 2009-12-15 14:25:50 EST
Created attachment 378595 [details]
Catch libvirt errors when trying to connect to VNC

This patch should fix the reported backtrace.
Comment 16 Cole Robinson 2009-12-15 14:42:48 EST
Fix built in virt-manager-0_6_1-9_el5
Comment 19 Johnny Liu 2010-01-11 00:14:12 EST
Verified PASS with virt-manager-0.6.1-12.el5 on RHEL5.4-Server-xen-x86_64.
Comment 21 errata-xmlrpc 2010-03-30 04:50:46 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2010-0281.html

Note You need to log in before you can comment on or make changes to this bug.