FAQ
I'm trying to set up a xen guest on a machine that already has a few others
running (not set up by me). It fails with the following error:

+ virt-install -r 512 -n host5 -f /dev/vol0/lvol5 --nographics -p --os-type=linux --os-variant=rhel5 --accelerate -l http://bla -x ks=http://bla/ks.cfg -m MA:CA:DD:RE:SS
Traceback (most recent call last):
File "/usr/bin/virt-install", line 31, in ?
import libvirt
File "/usr/lib64/python2.4/site-packages/libvirt.py", line 12, in ?
import cygvirtmod as libvirtmod
ImportError: No module named cygvirtmod

This is a standard CentOS 5.4 x86_64 install, and I have not been able to
find a solution on the web.

Search Discussions

  • Tait Clarridge at Jan 12, 2012 at 10:14 am

    On Thu, 2012-01-12 at 14:24 +0000, Lars Hecking wrote:
    I'm trying to set up a xen guest on a machine that already has a few others
    running (not set up by me). It fails with the following error:

    + virt-install -r 512 -n host5 -f /dev/vol0/lvol5 --nographics -p --os-type=linux --os-variant=rhel5 --accelerate -l http://bla -x ks=http://bla/ks.cfg -m MA:CA:DD:RE:SS
    Traceback (most recent call last):
    File "/usr/bin/virt-install", line 31, in ?
    import libvirt
    File "/usr/lib64/python2.4/site-packages/libvirt.py", line 12, in ?
    import cygvirtmod as libvirtmod
    ImportError: No module named cygvirtmod
    Do you have the libvirt-python package installed?
    Also check for the virt-viewer package (which helps with a lot of virt
    tool errors).

    Tait
  • Lars Hecking at Jan 12, 2012 at 10:21 am

    File "/usr/lib64/python2.4/site-packages/libvirt.py", line 12, in ?
    import cygvirtmod as libvirtmod
    ImportError: No module named cygvirtmod
    Do you have the libvirt-python package installed?
    Also check for the virt-viewer package (which helps with a lot of virt
    tool errors).
    These are installed:

    libvirt-0.6.3-20.1.el5_4
    libvirt-python-0.6.3-20.1.el5_4
    python-virtinst-0.400.3-12.el5
    virt-manager-0.6.1-8.el5
    virt-viewer-0.0.2-3.el5

    I found the erroneous code in /usr/lib64/python2.4/site-packages/libvirt.py,
    and comparing it with the CentOS 5.7 version, I can fix it. But I presume
    I need to generate .pyc and .po as well, not sure how to do that.
  • Chris Wik at Jan 12, 2012 at 10:37 am

    On 12.01.2012, at 16:21, Lars Hecking wrote:

    I found the erroneous code in /usr/lib64/python2.4/site-packages/libvirt.py,
    and comparing it with the CentOS 5.7 version, I can fix it. But I presume
    I need to generate .pyc and .po as well, not sure how to do that.

    Why on earth would you do that and not just 'yum update'?

    --
    Chris Wik
    Anu Internet Services Ltd
    www.cwik.ch | www.anu.net
  • Lars Hecking at Jan 12, 2012 at 10:51 am

    Chris Wik writes:
    On 12.01.2012, at 16:21, Lars Hecking wrote:

    I found the erroneous code in /usr/lib64/python2.4/site-packages/libvirt.py,
    and comparing it with the CentOS 5.7 version, I can fix it. But I presume
    I need to generate .pyc and .po as well, not sure how to do that.

    Why on earth would you do that and not just 'yum update'?
    Locked-down commercial environment, critical production server that cannot
    be taken down.

    I tried to just update the relevant packages, but there are too many
    dependencies.
  • Lars Hecking at Jan 12, 2012 at 11:31 am
    Found the problem. Someone thought it a good idea to have system-wide
    LD_LIBRARY_PATH settings in /etc/profile.d.

    D'oh.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcentos-virt @
categoriescentos
postedJan 12, '12 at 9:24a
activeJan 12, '12 at 11:31a
posts6
users3
websitecentos.org
irc#centos

People

Translate

site design / logo © 2022 Grokbase