>
> Ok, I tried linking one of the disk files to the default storage pool
> folder and it actually detected the linked volume in libvirt:
>

After issuing a *virsh pool-refresh default *the disk was correctly detected
and reported as a volume by *virsh vol-list default, *but there is a
problem:

The disk is added as a volume in libvirth with the path parameter
corresponding to the soft link ( for
example: /var/lib/libvirt/images/instance.0000002d_disk) instead of the disk
path ( /var/lib/nova/instances/instance-0000002d/disk ), this means that
disk lookups performed by hsflowd still fail, because they try to retrieve
volume information associated to disk path. (example:
virStorageLookupByPath(/var/lib/nova/instances/instance-0000002d/disk)
).

Hsflowd gets path information from the Virtual Machine XML definition (*virsh
dumpxml **instance.0000002d *shows, among many other details, the following
line:       <source
file='/var/lib/nova/instances/instance-0000002d/disk'/>), that is generated
and stored automatically by openstack into libvirt.xml (ex:
/var/lib/nova/instances/instance-0000002d/libvirt.xml).

So, to make it work this way, we should have a way to tell Nova/Openstack
 which path to look into to retrieve VM disks, and to create the related
soft links into the appropriate folder, when provisioning a new instance.


I also tried using virt.manager to create the pool but it didn't work, the
pool was created but no disk was detected, i suppose because libvirt expect
volumes to be located right into the folder specified as pool, and doesn't
look in any subfolder (creating the pool manually didn't work for that
reason).

Something I noticed that may be important is that virt-manager is able to
display disk statistics for those VM. I don't really know how it gets those
informations, but I believe it accesses disks using the  details contained
into <disk> </disk> tags located into the VM XML definition, instead of
doing a volume lookup starting from the volume path, like hsflowd is trying
to do.

Example:
<disk type='file' device='disk'>
      <driver name='qemu' type='qcow2'/>
      <source file='/var/lib/nova/instances/INSTANCENAME/disk'/>
      <target dev='vda' bus='virtio'/>
      <alias name='virtio-disk0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04'
function='0x0'/>
    </disk>

Could this be used in some way?
------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system, 
user administration capabilities and model configuration. Take 
the hassle out of deploying and managing Subversion and the 
tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2
_______________________________________________
Ganglia-general mailing list
Ganglia-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ganglia-general

Reply via email to