Bug 509985 - virt-manager: Traceback in populate_migrate_menu
Summary: virt-manager: Traceback in populate_migrate_menu
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: virt-manager
Version: 5.4
Hardware: All
OS: Linux
low
medium
Target Milestone: rc
: ---
Assignee: Cole Robinson
QA Contact: Virtualization Bugs
URL:
Whiteboard:
: 537867 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-07-07 09:56 UTC by Qunfang Zhang
Modified: 2018-10-27 15:55 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-03-30 08:51:01 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Error (31.44 KB, image/png)
2009-07-07 09:56 UTC, Qunfang Zhang
no flags Details
Backport of migrate dialog from upstream (71.20 KB, text/plain)
2009-12-15 19:20 UTC, Cole Robinson
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2010:0281 0 normal SHIPPED_LIVE virt-manager bug fix update 2010-03-29 13:59:22 UTC

Description Qunfang Zhang 2009-07-07 09:56:33 UTC
Created attachment 350764 [details]
Error

Description of problem:
"Automatically open consoles" can bring a error  when virt-manager restart.Just like the Steps to Reproduce.

Version-Release number of selected component (if applicable):
RHEL5.4-Server-x86_64(2.6.18-156.el5xen)
# rpm -qa | grep -E "libvirt |virt-manager|xen" 
virt-manager-0.6.1-5.el5
xen-3.0.3-88.el5
kernel-xen-2.6.18-156.el5
xen-libs-3.0.3-88.el5
xen-libs-3.0.3-88.el5
kernel-xen-devel-2.6.18-156.el5  

How reproducible:
100%

Steps to Reproduce:
1.Launch virt-manager
2.Click Edit->Preference on Virtual Machine Manager window.
3.Click VM Details on Preference window.
4.Select For all domains.
5.Click Close button.
6.Click Edit->Host Details->Overview,and check the Autoconnect on Host Details window.
7.Let all the vms runing and quit virt-manager
8.Launch virt-manager.

Actual result:
A error prompt pops up:Error bringing up domain details:'None Type' object has no attribute 'get_driver'.
Please catch the attachment.

Expected result:The console window can be open 
automatically.


Additional info:

Comment 1 Qunfang Zhang 2009-07-07 10:35:47 UTC
Error Details:

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/engine.py", line 272, in show_details
    details = vmmDetails(self.get_config(), con.get_vm(uuid), self)
  File "/usr/share/virt-manager/virtManager/details.py", line 329, in __init__
    self.update_widget_states(self.vm, self.vm.status())
  File "/usr/share/virt-manager/virtManager/details.py", line 739, in update_widget_states
    self.set_migrate_menu()
  File "/usr/share/virt-manager/virtManager/details.py", line 686, in set_migrate_menu
    self.engine.populate_migrate_menu(menu, self.control_vm_migrate)
  File "/usr/share/virt-manager/virtManager/engine.py", line 583, in populate_migrate_menu
    conns = self.get_available_migrate_hostnames()
  File "/usr/share/virt-manager/virtManager/engine.py", line 606, in get_available_migrate_hostnames
    driver = self.windowManager.current_connection().get_driver()
AttributeError: 'NoneType' object has no attribute 'get_driver'

Comment 2 Bryan Mason 2009-08-06 16:28:32 UTC
A customer has also reported this issue.  The traceback is the same, but their reproduction steps are slightly different.  They are:

(these are the same)
 1. Execute virt-manager
 2. Click Edit->Preference on Virtual Machine Manager window.
 3. Click VM Details on Preference window.
 4. Select For all domains.
 5. Click Close button.

(this is what's different)
 6. Start guest domain on other terminal (not using virt-manager -- i.e. using
    "virsh start guest_dom").

Comment 4 Cole Robinson 2009-12-13 22:30:19 UTC
I had filed a bug with the same issue, posting my comment here:

If a VM changes state while the details window is open, we attempt to
repopulate the migrate connection menu. However, the population function
erroneously depends on whatever is selected in the main manager view, which can
cause issues like below:

2009-11-12 17:29:56,383 DEBUG    Uncaught Error: Error bringing up domain
details: 'NoneType' object has no attribute 'get_driver' : Traceback (most
recent call last):
  File "/usr/share/virt-manager/virtManager/engine.py", line 272, in
show_details
    details = vmmDetails(self.get_config(), con.get_vm(uuid), self)
  File "/usr/share/virt-manager/virtManager/details.py", line 329, in __init__
    self.update_widget_states(self.vm, self.vm.status())
  File "/usr/share/virt-manager/virtManager/details.py", line 739, in
update_widget_states
    self.set_migrate_menu()
  File "/usr/share/virt-manager/virtManager/details.py", line 686, in
set_migrate_menu
    self.engine.populate_migrate_menu(menu, self.control_vm_migrate)
  File "/usr/share/virt-manager/virtManager/engine.py", line 583, in
populate_migrate_menu
    conns = self.get_available_migrate_hostnames()
  File "/usr/share/virt-manager/virtManager/engine.py", line 606, in
get_available_migrate_hostnames
    driver = self.windowManager.current_connection().get_driver()
AttributeError: 'NoneType' object has no attribute 'get_driver'

Comment 5 Cole Robinson 2009-12-13 22:30:30 UTC
*** Bug 537867 has been marked as a duplicate of this bug. ***

Comment 6 Cole Robinson 2009-12-15 19:20:41 UTC
Created attachment 378587 [details]
Backport of migrate dialog from upstream

This traceback should be fixed with the backported migrate dialog, which helps solve a number of bugs.

Comment 7 Cole Robinson 2009-12-15 19:41:35 UTC
Fix built in virt-manager-0_6_1-9_el5

Comment 13 errata-xmlrpc 2010-03-30 08:51:01 UTC
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.