[libvirt-users] how to match the ID of a LUN in a storage pool with the GUID on the target server

Tom Georgoulias tomg at mcclatchyinteractive.com
Wed Jun 16 17:20:02 UTC 2010


I've configured a libvirt storage pool using an iscsi target from a Sun 
7310 storage appliance and am using the LUNs in this target as volumes 
for my KVM guests.  The setup is very similar to what Daniel covered in 
a recent blog posting:

http://berrange.com/posts/2010/05/05/provisioning-kvm-virtual-machines-on-iscsi-the-hard-way-part-2-of-2/

It works great, but I can't figure out how to match the volume names & 
path IQNs within the storage pool to the GUIDs on the target.

For example, here's what I see when I use the vol-info command:

# virsh vol-list kvm-target
Name                 Path
-----------------------------------------
6.0.0.0 
/dev/disk/by-path/ip-X.X.X.X:3260-iscsi-iqn.1986-03.com.sun:02:<snipped>-lun-0
6.0.0.1 
/dev/disk/by-path/ip-X.X.X.X:3260-iscsi-iqn.1986-03.com.sun:02:<snipped>-lun-1

The IQN matches the targets IQN, but when I browse the LUNs from the 
storage system I do not see a way to determine which of them is *-lun-0 
and which is *-lun-1, I only see a GUID and an alias name that I created.

Is there any way to get that info (or something else that will do the 
job) from a virsh command?

Thanks in advance for any help.

Tom




More information about the libvirt-users mailing list