Bug 242900 - unable to remove network device
Summary: unable to remove network device
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: virt-manager
Version: 7
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Hugh Brock
QA Contact: Martin Jenner
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-06-06 10:59 UTC by David Robinson
Modified: 2008-01-22 15:38 UTC (History)
2 users (show)

Fixed In Version: 0.5.3-1.fc7
Clone Of:
Environment:
Last Closed: 2008-01-22 15:38:29 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description David Robinson 2007-06-06 10:59:11 UTC
Description of problem:
virt-manager gives a python traceback when attempting to remove a network
interface from a guest.

Version-Release number of selected component (if applicable):
# rpm -q virt-manager
virt-manager-0.4.0-2.fc7

How reproducible:
100%

Steps to Reproduce:
1. Assign an extra network interface to a guest
2. Remove the interface from the guest
  
Actual results:
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/details.py", line 478, in remove_network
    elif net[0] == "network":
NameError: global name 'net' is not defined

Expected results:
network interface is removed

Additional info:
patch below fixes the problem.

--- /usr/share/virt-manager/virtManager/details.py      2007-06-06
20:51:19.000000000 +1000
+++ /usr/share/virt-manager/virtManager/details.py.new  2007-06-06
20:50:56.000000000 +1000
@@ -475,7 +475,7 @@ class vmmDetails(gobject.GObject):
             vnic = None
             if netinfo[0] == "bridge":
                 vnic = virtinst.VirtualNetworkInterface(type=netinfo[0],
bridge=netinfo[1], macaddr=netinfo[3])
-            elif net[0] == "network":
+            elif netinfo[0] == "network":
                 vnic = virtinst.VirtualNetworkInterface(type=netinfo[0],
network=netinfo[1], macaddr=netinfo[3])
             else:
                 vnic = virtinst.VirtualNetworkInterface(type=netinfo[0],
macaddr=netinfo[3])

Comment 1 David Robinson 2007-06-06 11:02:20 UTC
Sorry, should provide more detail.

From the GUI, select a shutdown guest -> Details -> Hardware -> NIC eth0 -> Remove.

Comment 2 Hugh Brock 2007-06-13 17:40:49 UTC
Fixed at
http://hg.et.redhat.com/virt/applications/virt-manager--devel?cs=24f00545253e .
Will close when we push to f7.

Comment 3 Red Hat Bugzilla 2007-07-25 02:13:01 UTC
change QA contact

Comment 4 Fedora Update System 2008-01-11 22:26:46 UTC
virt-manager-0.5.3-1.fc7, gtk-vnc-0.3.2-1.fc7, python-virtinst-0.300.2-1.fc7, virt-viewer-0.0.2-1.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update virt-manager gtk-vnc python-virtinst virt-viewer'

Comment 5 Fedora Update System 2008-01-22 15:38:05 UTC
virt-manager-0.5.3-1.fc7, gtk-vnc-0.3.2-1.fc7, python-virtinst-0.300.2-1.fc7, virt-viewer-0.0.2-1.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.


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