
On Thu, Aug 02, 2012 at 11:32:14PM -0500, Doug Goldstein wrote:
On Thu, Aug 2, 2012 at 8:09 AM, Daniel P. Berrange <berrange@redhat.com> wrote:
From: "Daniel P. Berrange" <berrange@redhat.com>
Both LVM volumes and SCSI LUNs have a globally unique identifier associated with them. It is useful to be able to query this identifier to then perform disk locking, rather than try to figure out a stable pathname. --
Would it not be better to call methods from within libdevmapper and libblkid than relying on a callout? Its also worth noting that iSCSI provides a GUID for the volume as well.
AFAICT, libblkid does not provide a way to get the SCSI WWN/Serial values. For iSCSI, I'm assuming that the devices just report the data using the regular kernel SCSI ioctls, so scsi_id should 'just work' already. That said, I think I might implement the SCSI lookup directly because I know remember previous discussions about the fact that the scsi_id command changed its supported command line arguments over time. I might try libdevmapper, if I can figure out its crazy API Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|