]> xenbits.xensource.com Git - libvirt.git/commit
iscsi: Adjust error message for findStorageSources backend
authorJohn Ferlan <jferlan@redhat.com>
Wed, 25 Feb 2015 22:31:55 +0000 (17:31 -0500)
committerJohn Ferlan <jferlan@redhat.com>
Tue, 3 Mar 2015 03:57:27 +0000 (22:57 -0500)
commit30f69ae86b888ca4b2957454d16d8e9b1501a510
tree47b437878d49eacd395f14d3b321996950ae97fc
parent69db32f93d7a22e7be04c2e9dc41a357f9811404
iscsi: Adjust error message for findStorageSources backend

The virStorageBackendISCSIFindPoolSources API only needs the 'host' name
in order to discover iSCSI pools, it returns the various device paths.
On input, it's also possible to further restrict a search by providing the
port attribute for the host element and the (undocumented) initiator element.

For example:

$  virsh find-storage-pool-sources-as iscsi
error: Failed to find any iscsi pool sources
error: invalid argument: hostname and device path must be specified for iscsi sources

$ virsh find-storage-pool-sources-as iscsi 192.168.122.1
<sources>
  <source>
    <host name='192.168.122.1' port='3260'/>
    <device path='iqn.2013-12.com.example:iscsi-chap-lclpool'/>
  </source>
</sources>
src/storage/storage_backend_iscsi.c