Bug 1274677 - [ppc64le] After cloning a vm from a template, vm fails to start with XML error: target 'sda' duplicated for disk sources
[ppc64le] After cloning a vm from a template, vm fails to start with XML err...
Status: CLOSED CURRENTRELEASE
Product: ovirt-engine
Classification: oVirt
Component: BLL.Virt (Show other bugs)
3.6.0
Unspecified Unspecified
unspecified Severity high (vote)
: ovirt-3.6.1
: 3.6.1
Assigned To: Marek Libra
Ilanit Stein
virt
:
: 1281847 1281848 (view as bug list)
Depends On:
Blocks: RHEV3.6PPC
  Show dependency treegraph
 
Reported: 2015-10-23 06:48 EDT by Carlos Mestre González
Modified: 2016-02-21 08:30 EST (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-01-13 09:37:13 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: Virt
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
rule-engine: ovirt‑3.6.z+
mgoldboi: planning_ack+
rule-engine: devel_ack+
rule-engine: testing_ack+


Attachments (Terms of Use)
rest api calls (21.03 KB, text/plain)
2015-10-23 07:02 EDT, Carlos Mestre González
no flags Details
engine.log (245.43 KB, text/plain)
2015-10-23 07:03 EDT, Carlos Mestre González
no flags Details
vdsm.log (2.25 MB, text/plain)
2015-10-23 07:06 EDT, Carlos Mestre González
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
oVirt gerrit 48407 master MERGED core: Bootable disk index considers CDROM on PPC Never
oVirt gerrit 48964 ovirt-engine-3.6 MERGED core: Bootable disk index considers CDROM on PPC Never

  None (edit)
Description Carlos Mestre González 2015-10-23 06:48:59 EDT
Description of problem:
Clone a vm from a template and then start it fails. Not sure why is this the case since other multiple (similar) clone action works in the same run multiple times

Version-Release number of selected component (if applicable):
ovirt 3.6.0-15
vdsm-xmlrpc-4.17.9-1.el7ev.noarch
vdsm-python-4.17.9-1.el7ev.noarch
vdsm-jsonrpc-4.17.9-1.el7ev.noarch
vdsm-4.17.9-1.el7ev.noarch
vdsm-cli-4.17.9-1.el7ev.noarch
vdsm-infra-4.17.9-1.el7ev.noarch
vdsm-yajsonrpc-4.17.9-1.el7ev.noarch
libvirt-daemon-driver-nwfilter-1.2.17-13.el7.ppc64le
libvirt-daemon-driver-interface-1.2.17-13.el7.ppc64le
libvirt-daemon-driver-network-1.2.17-13.el7.ppc64le
libvirt-daemon-driver-nodedev-1.2.17-13.el7.ppc64le
libvirt-daemon-kvm-1.2.17-13.el7.ppc64le
libvirt-python-1.2.17-2.el7.ppc64le
libvirt-client-1.2.17-13.el7.ppc64le
libvirt-daemon-1.2.17-13.el7.ppc64le
libvirt-daemon-driver-secret-1.2.17-13.el7.ppc64le
libvirt-daemon-driver-storage-1.2.17-13.el7.ppc64le
libvirt-daemon-driver-qemu-1.2.17-13.el7.ppc64le
libvirt-daemon-config-nwfilter-1.2.17-13.el7.ppc64le
libvirt-lock-sanlock-1.2.17-13.el7.ppc64le
qemu-img-rhev-2.3.0-31.el7.ppc64le
qemu-kvm-tools-rhev-2.3.0-31.el7.ppc64le
qemu-kvm-rhev-2.3.0-31.el7.ppc64le
qemu-kvm-common-rhev-2.3.0-31.el7.ppc64le

How reproducible:
Not sure since I cannot pin point what's the specific issue here, clone & start seems to work

Steps to Reproduce:
1. Clone a vm from a template and start it with the Rest call attached

Actual results:
21:12:24 2015-10-19 21:12:27,558 - MainThread - plmanagement.error_fetcher - ERROR - Errors fetched from VDC(jenkins-vm-15.scl.lab.tlv.redhat.com): 2015-10-19 21:02:20,733 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (ForkJoinPool-1-worker-1) [] Correlation ID: null, Call Stack: null, Custom Event ID: -1, Message: VM storage_vm_server is down with error. Exit message: XML error: target 'sda' duplicated for disk sources '/rhev/data-center/c46b2a29-2767-4450-9d26-0d0fc3b0cba0/1c8e846d-5ae3-4b17-a2ac-b2ef63107115/images/8325d3ea-e787-4bed-ad98-efc1a3426a70/a3a5b85a-1cc9-4734-b345-0f63e9a28560' and '<null>'.
21:12:24 2015-10-19 21:02:20,733 INFO  [org.ovirt.engine.core.vdsbroker.VmAnalyzer] (ForkJoinPool-1-worker-1) [] Running on vds during rerun failed vm: 'd40172dd-0600-420b-9e4b-2456349843aa'
21:12:24 2015-10-19 21:02:20,744 ERROR [org.ovirt.engine.core.vdsbroker.VmsMonitoring] (ForkJoinPool-1-worker-1) [] Rerun VM '31842175-0cd2-4678-9cb0-16c5c3288172'. Called from VDS 'host_mixed_1'
21:12:24 2015-10-19 21:02:20,753 WARN  [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (org.ovirt.thread.pool-7-thread-12) [] Correlation ID: vms_syncAction_37c8fab8-3df7-4288, Job ID: 2da808c9-19c6-468e-b704-8261a88b2635, Call Stack: null, Custom Event ID: -1, Message: Failed to run VM storage_vm_server on Host host_mixed_1.
21:12:24 2015-10-19 21:02:38,605 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (DefaultQuartzScheduler_Worker-30) [] Correlation ID: null, Call Stack: null, Custom Event ID: -1, Message: VM storage_vm_server is down with error. Exit message: XML error: target 'sda' duplicated for disk sources '/rhev/data-center/c46b2a29-2767-4450-9d26-0d0fc3b0cba0/1c8e846d-5ae3-4b17-a2ac-b2ef63107115/images/8325d3ea-e787-4bed-ad98-efc1a3426a70/a3a5b85a-1cc9-4734-b345-0f63e9a28560' and '<null>'.
21:12:24 2015-10-19 21:02:38,605 INFO  [org.ovirt.engine.core.vdsbroker.VmAnalyzer] (DefaultQuartzScheduler_Worker-30) [] Running on vds during rerun failed vm: 'null'

I'm adding this to Virt for the moment.
Comment 1 Carlos Mestre González 2015-10-23 07:02 EDT
Created attachment 1085815 [details]
rest api calls
Comment 2 Carlos Mestre González 2015-10-23 07:03 EDT
Created attachment 1085816 [details]
engine.log

20:59:32 starts the vm creation.
Comment 3 Carlos Mestre González 2015-10-23 07:06 EDT
Created attachment 1085817 [details]
vdsm.log

Sorry, the host time doesn't match the one from the engine. check 2015-10-19 14:02:39,748
Comment 4 Allon Mureinik 2015-10-28 14:10:13 EDT
Michal - can your team take lead on this please? If you decide it's more of a storage issue than a virt one, we'll take it off your hands, of course.
Comment 5 Tomas Jelinek 2015-10-29 08:58:41 EDT
yep, seems like virt.
Comment 6 Red Hat Bugzilla Rules Engine 2015-10-29 18:47:28 EDT
This bug is not marked for z-stream, yet the milestone is for a z-stream version, therefore the milestone has been reset.
Please set the correct milestone or add the z-stream flag.
Comment 7 Marek Libra 2015-11-10 02:41:30 EST
The CDROM is assigned to sda. Subsequent disk assignment is incorrectly handled (starting from sda as well).
The bug can be fixed by setting correct "index" attribute for disk sent from engine in case of VirtIO-SCSI.
Comment 8 Marek Libra 2015-11-11 04:11:23 EST
Update of comment 7: the disk index is incorrectly set for first bootable disk.
Comment 9 Allon Mureinik 2015-11-16 03:54:01 EST
*** Bug 1281847 has been marked as a duplicate of this bug. ***
Comment 10 Amit Aviram 2015-11-16 09:51:45 EST
*** Bug 1281848 has been marked as a duplicate of this bug. ***
Comment 11 Ilanit Stein 2015-12-29 02:56:34 EST
Verified on rhevm 3.6.1-4.

Create the VM:
=============

https://<engine IP address>:443/ovirt-engine/api/vms  
POST
Headers: Content-Type: application/xml

<vm>
    <name>storage_vm_server</name>
    <type>server</type>
    <os type="rhel_7_ppc64"/>
    <cluster href="/api/clusters/2d5db03a-7a36-490b-84b6-a0722411e588" id="2d5db03a-7a36-490b-84b6-a0722411e588">
        <name>golden_env_mixed_1</name>
    </cluster>
    <display>
        <type>vnc</type>
    </display>
    <virtio_scsi enabled="true"/>
    <template href="/api/templates/e22d3cbf-43d1-4341-a3dc-e5ac0cebd26d" id="e22d3cbf-43d1-4341-a3dc-e5ac0cebd26d">
        <name>golden_mixed_virtio_template</name>
    </template>
    <disks>
        <disk id="c44da4a5-0679-4f9b-9ae9-baeef0beba29">  <== Template's disk id
            <storage_domains>
                <storage_domain>
                    <name>iscsi_0</name>                  
                </storage_domain>
            </storage_domains>
            <format>cow</format>
            <sparse>true</sparse>
        </disk>
        <clone>true</clone>
    </disks>
    <memory_policy/>
</vm>


Start the VM:
============
https://<engine IP address>:443/ovirt-engine/api/vms/878a7f92-94d8-4dad-8835-245c6c30c22f/start
POST
Headers: Content-Type: application/xml

<action>
    <async>false</async>
    <grace_period>
        <expiry>10</expiry>
    </grace_period>
</action>
Comment 12 Sandro Bonazzola 2016-01-13 09:37:13 EST
oVirt 3.6.1 has been released, closing current release

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