[xenial] virt-install aborts with ImportError: No module named ipaddr

Bug #1556671 reported by Doug Smythies
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
virt-manager (Debian)
Fix Released
Unknown
virt-manager (Ubuntu)
Fix Released
Undecided
Marc Deslauriers

Bug Description

The server is a fresh install on 16.04 server edition. However, and due to bug 1517746, some tasks were added post installation using tasksel.

virt-install is aborting:

doug@s15:~/iso$ sudo virt-install -n desk_tt -r 8192 \
--disk path=/media/newhd/desk_tt.img,bus=virtio,size=50 \
-c ubuntu-14.04.3-desktop-amd64.iso \
--network bridge=br0,model=virtio \
--video=vmvga --graphics vnc,listen=0.0.0.0 --noautoconsole -v --vcpus=4

Traceback (most recent call last):
  File "/usr/share/virt-manager/virt-install", line 28, in <module>
    import virtinst
  File "/usr/share/virt-manager/virtinst/__init__.py", line 57, in <module>
    from virtinst.interface import Interface, InterfaceProtocol
  File "/usr/share/virt-manager/virtinst/interface.py", line 26, in <module>
    import ipaddr
ImportError: No module named ipaddr

Indeed /usr/share/virt-manager/virtinst/interface.py line 26 is:

import ipaddr

and ipaddr does not exist.

Tags: xenial
tags: added: virtualization xenial
tags: removed: virtualization
Revision history for this message
Doug Smythies (dsmythies) wrote :

It seems there is a package called "python-ipaddr" and once it is installed, one gets past this error. However the next one is:

  File "/usr/share/virt-manager/virtinst/urlfetcher.py", line 27, in <module>
    import requests
ImportError: No module named requests

O.K. so there seems to be a package called "python-requests" and once it is installed, one gets past this error.
And now, the virt-install sems to continue.

So, I guess this bug report becomes why aren't the dependencies satisfied at the:

sudo apt-get install virtinst

step?

Revision history for this message
Marc Deslauriers (mdeslaur) wrote :

They are listed as depends of the virt-manager package, not the virtinst package.
I guess they should also be listed for virtinst.

Changed in virt-manager (Ubuntu):
status: New → Confirmed
Revision history for this message
Marc Deslauriers (mdeslaur) wrote :
Changed in virt-manager (Ubuntu):
assignee: nobody → Marc Deslauriers (mdeslaur)
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (3.3 KiB)

This bug was fixed in the package virt-manager - 1:1.3.2-3ubuntu1

---------------
virt-manager (1:1.3.2-3ubuntu1) xenial; urgency=medium

  * Merge from Debian. Remaining changes: (LP: #1556671)
    - debian/control:
        + Depend on gir1.2-appindicator3-0.1 for appindicator support.
        + Add lsb-release to Build-Depends so we can detect whether we're
          running on Ubuntu or Debian.
        + Change Recommends to libvirt-bin instead of libvirt-daemon-system
          which isn't available in Ubuntu
    - debian/rules:
        + Set qemu user to libvirt-qemu so appropriate permissions get set.
        + Set the preferred distro so we appear first in the list.
        + Remove data/gschemas.compiled generated by clean.
    - d/p/virtinst/9006_fix_path_to_qemu-dm.patch: drop the full path from
      qemu-dm as already done for hvmloader and pygrub. The Xen tools will
      handle this and add the missing path.
    - d/p/more_helpful_error_message.patch: explain to the user why
      connecting to qemu:///system failed and how to fix it.
    - d/p/use_ubuntu_package_names.patch: Suggest installing the packages
      that are actually available in Ubuntu.
    - d/p/leave-mnemonics-alone-on-focus-change.patch: Leave
      gtk-enable-mnemonics setting alone under Unity when windows change
      focus.
    - d/p/mark-libvirt-lxc: Clearly mark the LXC connections as being
      libvirt-lxc, to avoid confusion due to differing features and
      configurations.
    - d/p/add_qemu_binaries.patch: add the actual binary name from the qemu
      packages so default hypervisor detection works properly on first run.
    - d/p/use_qxl_for_ubuntu.patch: use qxl by default for Ubuntu VMs, it
      seems to work better than vmvga now.
    - d/p/prefer-qemu.patch: Prefer QEMU as the default URI, even if it's
      not installed.
    - d/p/virtinst/dont_disable_vmport.patch: Don't disable vmport even if
      we're using spice, as this prevents having a seamless mouse when
      using Ubuntu as a guest.

virt-manager (1:1.3.2-3) unstable; urgency=medium

  * [2ebfe49] Switch from urlgrabber to requests.
    Thanks to Adel Belhouane (Closes: #819494)
  * [b1ee5b4] Invoke virt-* on autopkg test to check for missing imports
  * [777d781] Add missing dependency on python-gi catched by the autopkg test

virt-manager (1:1.3.2-2) unstable; urgency=medium

  * Upload to unstable
  * [8a27ee8] Fix spice availability detection
    gi.require_version('SpiceClientGtk', '3.0') raises ValueError if
    SpiceClientGtk is not installed so we never see ImportError. Check for
    both in case the module is there but the symbol went missing.
    Thanks: Adel Belhouane for the patch
    (Closes: #799771)

virt-manager (1:1.3.2-1) experimental; urgency=medium

  * [74c0cce] Move python-ipaddr dependency from virt-manager to virtinst
    (Closes: #803469)
  * [b6de3ae] New upstream version 1.3.2
  * [1935c7d] Use README.source template from gbp
  * [203bfe9] Rediff patches
  * [1b96d13] gbp.conf: Use upstream/latest as upstream branch as recommended
    by DEP-14
  * [6a2a8a1] Use secure and canical VCS URLs
  * [b54e442] Pass --no-update-icon-cache --no-compile-schemas...

Read more...

Changed in virt-manager (Ubuntu):
status: Confirmed → Fix Released
Changed in virt-manager (Debian):
status: Unknown → Fix Released
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.