无法安装包pythonguestfs

2024-09-21 03:10:48 发布

您现在位置:Python中文网/ 问答频道 /正文

我有ubuntu11.10(oneiric),我试着运行一个名为snf image creator的程序(它是用来创建虚拟机的) 我得到了一个错误:

File "/usr/local/bin/snf-image-creator", line 9, in <module>
load_entry_point('snf-image-creator==0.5.1', 'console_scripts', 'snf-image-creator')()
File "build/bdist.linux-x86_64/egg/pkg_resources.py", line 351, in load_entry_point
def get_resource_filename(manager, resource_name):
File "build/bdist.linux-x86_64/egg/pkg_resources.py", line 2363, in load_entry_point
def clone(self,**kw):
File "build/bdist.linux-x86_64/egg/pkg_resources.py", line 2088, in load

File "/usr/local/lib/python2.7/dist-packages/snf_image_creator-0.5.1-py2.7.egg/image_creator/main.py", line 42, in <module>
  from image_creator.disk import Disk
File "/usr/local/lib/python2.7/dist-packages/snf_image_creator-0.5.1-py2.7.egg/image_creator/disk.py", line 43, in <module>
from image_creator.image import Image
File "/usr/local/lib/python2.7/dist-packages/snf_image_creator-0.5.1-py2.7.egg/image_creator/image.py", line 41, in <module>
import guestfs

ImportError:没有名为guestfs的模块

所以我试着安装客房。我用apt get install python guestfs 但我得到的信息是:

^{pr2}$

我还绑定了apt get install guestfs或libguestfs,python libguestfs。我在http://packages.ubuntu.com/中搜索了这个包,得到了结果。我也使用命令

sudo apt-file find guestfs 

但它没有返回任何东西。同时命令

 aptitude install libguestfs 
 aptitude install guestfs

也因为oneiric不再受支持,所以我在/etc/apts中进行了更改/来源.列表 链接到:

 http://old-releases.ubuntu.com/ubuntu/

然后我做了

apt-get update
apt-get upgrade

我不知道还能做什么。在


Tags: inpyimagegeteggusrlocalline
2条回答

如果您安装了guestfs,那么您应该能够从github下载Python源代码:

然后您就可以进行Python源代码安装。通常只需要这样做:

python setup.py install

你可能得在前面加上sudo。在

11.10已经有将近一年没有支持了。您可以尝试源代码安装,说明在项目自述文件中:

https://github.com/libguestfs/libguestfs

相关问题 更多 >

    热门问题