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 1159030 - libvirt backend does not set RBD password
Summary: libvirt backend does not set RBD password
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libguestfs
Version: 7.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Richard W.M. Jones
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On: 1140742 1140744 1159016
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-10-30 17:52 UTC by Daniel Berrangé
Modified: 2015-11-19 06:57 UTC (History)
14 users (show)

Fixed In Version: libguestfs-1.28.1-1.25.el7
Doc Type: Bug Fix
Doc Text:
Clone Of: 1159016
Environment:
Last Closed: 2015-11-19 06:57:42 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:2183 0 normal SHIPPED_LIVE libguestfs bug fix and enhancement update 2015-11-19 08:18:42 UTC

Description Daniel Berrangé 2014-10-30 17:52:32 UTC
+++ This bug was initially created as a clone of Bug #1159016 +++

Description of problem:
After configuring an RBD disk with libguestfs I get this error when launching the appliance


2014-10-30 16:53:24.859 TRACE nova.compute.manager [instance: 3f8c2d01-4b07-4864-b3ed-7a45bc2b95bd] Original error from libvirt: XML error: missing auth secret uuid or usage attribute [code=27 domain=18])

Forcing the backend to 'direct' successfully launches

I can see the XML libguesfs builds is:

    <disk device="disk" type="network">
      <source protocol="rbd" name="2f98aa3a-c005-4c21-8fb3-595a5a698005_disk/vms">
        <host name="10.33.9.42" port="6789"/>
      </source>
      <auth username="cinder"/>
      <target dev="sda" bus="scsi"/>
      <driver name="qemu" type="raw" cache="writeback"/>
      <address type="drive" controller="0" bus="0" target="0" unit="0"/>
    </disk>

The auth XML element should refer to a secret

      <auth username="cinder">
        <secret type="ceph" uuid="457eb676-33da-42ec-9a8c-9293d545c337"/>
      </auth>


Version-Release number of selected component (if applicable):
libguestfs-1.26.9-1.fc20.x86_64

--- Additional comment from Daniel Berrange on 2014-10-30 17:51:36 GMT ---

Ah ha, seems this is a known todo item

          start_element ("auth") {
            attribute ("username", drv->src.username);
            /* TODO: write the drive secret, after first storing it separately
             * in libvirt
             */
          } end_element ();

Comment 7 Richard W.M. Jones 2015-04-13 14:23:21 UTC
Note that in order to implement this fix, I had to enable
rbd (Ceph) support in libguestfs in RHEL 7.2.

Comment 9 Hu Zhang 2015-10-10 08:22:49 UTC
Verified with the packages:
libguestfs-1.28.1-1.55.el7.x86_64

Verify steps:
1. Configuring an RBD disk. Add a user libguestfs.
2. On client:
# guestfish
><fs> add-drive gs/gs1.img format:raw protocol:rbd server:hostname:6789 username:libguestfs secret:$key
><fs> run
><fs> part-disk /dev/sda mbr
><fs> list-filesystems 
/dev/sda1: unknown
><fs> mkfs ext3 /dev/sda1
><fs> mount /dev/sda1 /
><fs> ls /
lost+found

So verified.

Comment 11 errata-xmlrpc 2015-11-19 06:57:42 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.

https://rhn.redhat.com/errata/RHBA-2015-2183.html


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