Bug 1358271 - [v4 API only]: <logical_name> property (device name for disk) missing from disk attachments v4
Summary: [v4 API only]: <logical_name> property (device name for disk) missing from di...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: RestAPI
Version: 4.0.1.1
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ovirt-4.0.4
: 4.0.4
Assignee: Idan Shaby
QA Contact: Raz Tamir
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-07-20 12:10 UTC by Carlos Mestre González
Modified: 2016-09-26 12:34 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-09-26 12:34:49 UTC
oVirt Team: Storage
Embargoed:
rule-engine: ovirt-4.0.z+
ylavi: blocker-
rule-engine: planning_ack+
amureini: devel_ack+
acanan: testing_ack+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 61555 0 master MERGED Add logicalName to DiskAttachment 2016-07-28 09:37:47 UTC
oVirt gerrit 61606 0 master MERGED core: add logicalName to DiskAttachment 2016-08-03 09:14:08 UTC
oVirt gerrit 61620 0 model_4.0 MERGED Add logicalName to DiskAttachment 2016-07-28 12:02:45 UTC
oVirt gerrit 61894 0 ovirt-engine-4.0 MERGED core: add logicalName to DiskAttachment 2016-08-03 13:29:27 UTC

Description Carlos Mestre González 2016-07-20 12:10:21 UTC
Description of problem:
Cannot get the device name for a disk in a vm. Before it was in /vms/{vm:id}/disks/{disk:id} under <logical_name>, now that disks is missing is not under /vms/{vm:id}/diskattachments/{disk:id}


Version-Release number of selected component (if applicable):
rhevm-4.0.1.1-0.1.el7ev.noarch

How reproducible:
100%

Steps to Reproduce:
1. Create a vm with OS and rhevm-guest-agent
2. Try to get the logical name for the disk with GET /vms/{vm:id}/diskattachments/{disk:id}

Actual results:
no logical_name

Expected results:
Should return the logical_name property with the device name for that disk for that vm.

Additional info:
The logical name still works in v3 in the same system, GET /vms/{vm:id}/disks/{disk:id} returns the <logical_name> successfully.

I'm setting the severity high since this is blocking quite a few of our tests.

Comment 1 Red Hat Bugzilla Rules Engine 2016-07-20 13:07:25 UTC
This bug report has Keywords: Regression or TestBlocker.
Since no regressions or test blockers are allowed between releases, it is also being identified as a blocker for this release. Please resolve ASAP.

Comment 2 Tal Nisan 2016-07-20 13:38:56 UTC
Strange, haven't touched this field at all, it might be from the move to V4, will look into it

Comment 3 Allon Mureinik 2016-07-25 11:17:37 UTC
Idan, this has become important, and Tal is on PTO. Can you take a look at this please?

Comment 4 Idan Shaby 2016-07-26 08:54:40 UTC
I can't see any information regarding the logical_name on the v3 api.
The only thing that I see additionally to the info I got before installing ovirt-guest-agent is:

<guest_info>
  <ips>
    <ip address="..." version="v4"/>
    <ip address="..." version="v6"/>
    <ip address="..." version="v6"/>
  </ips>
</guest_info>

inside the <vm> property under:
/ovirt-engine/api/v3/vms/<vm_id>/disks/<disk_id>

Do I need to do anything else to get that disk's logical name?
Also, which OS did you install on the vm?

Comment 5 Carlos Mestre González 2016-07-26 09:48:18 UTC
It should work just with the guest agent installed, from v3:

<disks>
     [...]
        <name>golden_mixed_virtio_template</name>
        <description>golden_env_mixed_virtio_0_Disk1 (39a611d)</description>
    [...]
            <guest_info>
                <ips>
                    <ip address="10.35.81.234" version="v4"/>
                    <ip address="fe80::21a:4aff:fe16:81ea" version="v6"/>
                </ips>
            </guest_info>
        </vm>
        [...]
        <disk_profile href="/ovirt-engine/api/diskprofiles/baea7b49-d346-46e9-ab9a-b927f3fd497b" id="baea7b49-d346-46e9-ab9a-b927f3fd497b"/> <logical_name>/dev/vda</logical_name>
        <storage_type>image</storage_type>
    </disk>
</disks>

guest os: RHEL 6.8
rhevm-guest-agent-1.0.11-6

Comment 7 Raz Tamir 2016-09-01 14:21:58 UTC
verified on ovirt-engine-4.0.4-0.1.el7ev.noarch

<disk_attachments>
<disk_attachment href="/ovirt-engine/api/vms/7c3312d0-f4bf-4c55-af82-e0b3c6d77598/diskattachments/f09976fc-712b-44fe-b14d-252f3e22d21f" id="f09976fc-712b-44fe-b14d-252f3e22d21f">
<active>true</active>
<bootable>false</bootable>
<interface>virtio</interface>

<logical_name>/dev/vda</logical_name>  <---    ***VERIFIED***

<disk href="/ovirt-engine/api/disks/f09976fc-712b-44fe-b14d-252f3e22d21f" id="f09976fc-712b-44fe-b14d-252f3e22d21f"/>
<vm href="/ovirt-engine/api/vms/7c3312d0-f4bf-4c55-af82-e0b3c6d77598" id="7c3312d0-f4bf-4c55-af82-e0b3c6d77598"/>
</disk_attachment>
</disk_attachments>


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