On Fri, May 23, 2008 at 11:32:37AM +0530, sarveswara rao mygapula wrote:
Hi,
I am just trying to use libvirt storage api from python terminal, and i am
getting the following error.
>>> import libvirt
>>> con = libvirt.open(<my uri using ssh>)
>>> con.numOfDefinedStoragePools()
libvir: Remote error : Broken pipe
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.5/libvirt.py", line 1022, in
numOfDefinedStoragePools
ret = libvirtmod.virConnectNumOfDefinedStoragePools(self._o)
AttributeError: 'module' object has no attribute
'virConnectNumOfDefinedStoragePools'
>>>
The version of the python binding you are using is different from the
version of libvirt C library. I guess you're install is done properly,
or you installed it in a non-standard location and have not set the
neccessary LD_LIBRARY_PATH/PYTHONPATH environemnt variables.
That all said, I've just noticed there is another bug in the python
bindings that would prevent this method from working. I'll fix that
shortly.
Dan
--
|: Red Hat, Engineering, Boston -o-
http://people.redhat.com/berrange/ :|
|:
http://libvirt.org -o-
http://virt-manager.org -o-
http://ovirt.org :|
|:
http://autobuild.org -o-
http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|