RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 823850 - find-storage-pool-sources/ find-storage-pool-sources-as can't return XML describing of netfs/iscsi pool
Summary: find-storage-pool-sources/ find-storage-pool-sources-as can't return XML desc...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt
Version: 6.3
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Gunannan Ren
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-05-22 10:10 UTC by zhpeng
Modified: 2013-09-09 00:03 UTC (History)
9 users (show)

Fixed In Version: libvirt-0.10.0-0rc1.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-02-21 07:15:14 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2013:0276 0 normal SHIPPED_LIVE Moderate: libvirt security, bug fix, and enhancement update 2013-02-20 21:18:26 UTC

Description zhpeng 2012-05-22 10:10:35 UTC
Description of problem:
find-storage-pool-sources/ find-storage-pool-sources-as can't return XML describing of netfs/iscsi pool

Version-Release number of selected component (if applicable):


How reproducible:
100%

Steps to Reproduce:
virsh # pool-list
Name                 State      Autostart
-----------------------------------------
bbb                  active     yes      ------> logical pool
default              active     yes      
iscsi                active     no       ------> iscsi pool
mnt                  active     yes      
nfs                  active     no       ------> netfs pool

virsh # find-storage-pool-sources logical
<sources>
  <source>
    <device path='/dev/sdb'/>
    <name>bbb</name>
    <format type='lvm2'/>
  </source>
</sources>

virsh # find-storage-pool-sources iscsi
error: Failed to find any iscsi pool sources
error: (storage_source_specification):1: Document is empty
(null)
^

virsh # find-storage-pool-sources netfs
error: Failed to find any netfs pool sources
error: (storage_source_specification):1: Document is empty
(null)
^

Actual results:
Can't return XML describing of netfs/iscsi pool

Expected results:
Works well

Additional info:

Comment 2 Gunannan Ren 2012-06-01 08:26:52 UTC
The --srcSpec should be optional, the code doesn't check the value of it before passing it, so it reports a xml parsing error:(storage_source_specification):1: Document is empty (null).

Comment 4 Gunannan Ren 2012-07-16 15:22:06 UTC
patch sent to upstream
https://www.redhat.com/archives/libvir-list/2012-July/msg00659.html

Comment 5 Gunannan Ren 2012-08-02 03:11:54 UTC
commit 4057048891dc853da7793e7978e8c9c38a13934a
Author: Guannan Ren <gren>
Date:   Tue Jul 31 16:56:41 2012 +0800

    storage: netfs and iscsi need option srcSpec for resource discovery
    
    The option 'srcSpec' to virsh command find-storage-pool-sources
    is optional for logical type of storage pool, but mandatory for
    netfs and iscsi type.
    When missing the option for netfs and iscsi, libvirt reports XML
    parsing error due to null string option srcSpec.

Comment 7 zhe peng 2012-08-24 07:59:34 UTC
can reproduce this with libvirt-0.10.0-0rc0.el6

verify with libvirt-0.10.0-0rc1.el6

step:
  1: prepare netfs & iscsi pool
#virsh pool-list --all
Name                 State      Autostart 
-----------------------------------------
A                    active     no          ----iscsi 
default              active     no        
mpath                inactive   no        
mylvm                active     yes         ----logical
nfs                  active     yes         ----netfs

#virsh find-storage-pool-sources 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 iscsi iscsi.xml
<sources>
  <source>
    <host name='10.66.90.100'/>
    <device path='iqn.2001-05.com.equallogic:0-8a0906-12a1f7d03-0daf49b25a84ee02-s3-kyla-131842'/>
  </source>
  <source>
    <host name='10.66.90.100'/>
    <device path='iqn.2001-05.com.equallogic:0-8a0906-9951f7d03-34cf49b25f04f94b-libvirt-2-150313'/>
  </source>
  <source>
    <host name='10.66.90.100'/>
    <device path='iqn.2001-05.com.equallogic:0-8a0906-6eb1f7d03-30cf49b25f24f94d-libvirt-1-150313'/>
  </source>
</sources>



#virsh find-storage-pool-sources netfs
error: Failed to find any netfs pool sources
error: invalid argument: hostname must be specified for netfs sources

#virsh find-storage-pool-sources netfs nfs.xml
<sources>
  <source>
    <host name='10.66.6.166'/>
    <dir path='/common'/>
    <format type='nfs'/>
  </source>
</sources>


verification passed.

Comment 8 errata-xmlrpc 2013-02-21 07:15:14 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHSA-2013-0276.html


Note You need to log in before you can comment on or make changes to this bug.