Description of problem: When trying to create a vm from a template with QCOW disks (created from a vm with raw and cow disks) without clone (thin), the operation succeeds, creating the disks but not matching the disk format set in the request. In the Web UI the operation is blocked since you can only set the disks to RAW once you select clone, but in REST it allows the operation and creates the disks. Version-Release number of selected component (if applicable): rhevm-4.0.2-0.1.rc.el7ev.noarch How reproducible: 100% Steps to Reproduce: 1. Create a vm with a cow sparse and raw no sparse disk 2. Create a template from the VM with COW format (QCOW) disks 3. Create a vm from the previous template with the REST API without clone selecting the disks as RAW: <vm> <name>template_manual_rest_raw_no_clone2</name> <cluster><name>golden_env_mixed_1</name></cluster> <disk_attachments> <disk_attachment> <interface>virtio</interface> <disk id="22d677b6-302a-4b94-8b49-e44932861510"> <format>raw</format> </disk> </disk_attachment> <disk_attachment> <interface>virtio</interface> <disk id="0f7e5f74-c1c5-466a-93a7-b1e0ec2eb1f5"> <format>raw</format> </disk> </disk_attachment> </disk_attachments> <template><name>vm_TestCase16408_REST_NFS_28170411</name></template> </vm> Actual results: Operation succeeds, creating a vm with two disks, one RAW and one COW (the requested asked for both being RAW) In the Web UI this operation is not allowed, only you're able to create the template when you mark it as clone. Expected results: Error stating that the request cannot be fulfil. Additional info:
Is this v3 or v4 API?
V4
Creating the vm shows an error message: <fault> <detail> [Cannot add VM. Thin provisioned template disks can not be defined as Raw.] </detail> <reason>Operation Failed</reason> </fault> rhevm-4.0.6-0.1.el7ev.noarch