Open ahadas opened 2 years ago
Should probably be handled in https://github.com/oVirt/ovirt-engine/blob/b99c10c903e4f745793efa4b56c85a3ad38be269/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/libvirt/VmDevicesConverter.java#L94-L109
by checking the ovirt-vm:managed
metadata key
I've been using an ansible playbook to create disks in oVirt and format and mount them on the hosts. With image-based disks, the ansible API returns the logical disk name in the guest when the disk is created. However, with MBS-based disks, this field is not returned. I don't think this is purely an ansible API issue, as the web UI also does not show the Logical Device under the Disks tab on the VM if it's an MBS disk.
Version-Release number of selected component (if applicable):
All hosts and engine updated to latest oVirt 4.4.10.
How reproducible:
Attach MBS disk to a VM instead of an image-based disk.
Steps to Reproduce:
Actual results:
Logical Disks field is empty.
Expected results:
Logical Disks field is populated.
Additional info:
If it's useful, here's the relevant bit of the playbook. I haven't been able to find any alternate way to correlate a new unformatted disk attached in oVirt with the device inside the guest without a whole lot of extra work within the OS to try to detect new disks.
name: create and mount disk on vm when: ovirt_auth.token is defined block:
name: create disk in ovirt ovirt.ovirt.ovirt_disk: auth: "{{ ovirt_auth }}" vm_name: "{{ ansible_fqdn }}" name: "{{ ansiblefqdn }}{{ disk_name }}" size: "{{ disk_size }}" format: "{{ ovirt_disk_format }}" interface: "{{ ovirt_disk_interface }}" storage_domain: "{{ ovirt_storage_domain }}" fetch_nested: yes register: ovirt_disk_info delegate_to: localhost
name: create filesystem filesystem: dev: "{{ ovirt_disk_info.diskattachment.logical_name }}" fstype: "{{ mount_fstype }}" opts: "-L {{ disk_name }}" resizefs: yes when: ovirt_disk_info.changed
name: mount filesystem mount: path: "{{ mount_path }}" src: "LABEL={{ disk_name }}" fstype: "{{ mount_fstype }}" state: mounted
Original bug: https://bugzilla.redhat.com/2064080