Bug 1082979 - Run once vm with attached cd, not attach payload
Summary: Run once vm with attached cd, not attach payload
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 3.4.0
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
: 3.5.0
Assignee: Shahar Havivi
QA Contact: Artyom
URL:
Whiteboard: virt
Depends On:
Blocks: 1099507 rhev3.5beta 1156165
TreeView+ depends on / blocked
 
Reported: 2014-04-01 08:54 UTC by Artyom
Modified: 2015-02-17 08:29 UTC (History)
13 users (show)

Fixed In Version: vt1.3
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1099507 (view as bug list)
Environment:
Last Closed: 2015-02-17 08:29:00 UTC
oVirt Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
engine and vdsm logs (67.65 KB, application/zip)
2014-04-01 08:54 UTC, Artyom
no flags Details
vdsm log with windows vm (866.58 KB, text/x-log)
2014-04-27 09:08 UTC, Artyom
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 27444 0 master MERGED core: Payload is not attach via run once. Never
oVirt gerrit 27499 0 ovirt-engine-3.4 MERGED core: Payload is not attach via run once. Never

Description Artyom 2014-04-01 08:54:23 UTC
Created attachment 881248 [details]
engine and vdsm logs

Description of problem:
If you run vm with payload, via run once mode with attached cd(boot order no matter, you can leave hd first), payload cdrom(generally it /dev/sr1) not appear under /dev in OS and you can see just one cdrom, that you attached.

Version-Release number of selected component (if applicable):
is35.1, av5

How reproducible:
Always

Steps to Reproduce:
1. Create new vm with payload(type=cdrom)
2. Start vm via run once mode with attached cd(you will need to attach some iso_domain, to choose some cd)
3. Enter to vm, and check that /dev/sr1 not appear

Actual results:
Payload device /dev/sr1 not appear

Expected results:
Payload device /dev/sr1 appear

Additional info:

Comment 1 Michal Skrivanek 2014-04-04 09:27:33 UTC
No idea why there should be any /dev/sr1 
Both CDs are created and attached:

        <disk device="cdrom" snapshot="no" type="file">
            <address bus="1" controller="0" target="0" type="drive" unit="0"/>
            <source file="" startupPolicy="optional"/>
            <target bus="ide" dev="hdc"/>
            <readonly/>
            <serial/>
        </disk>
        <disk device="cdrom" snapshot="no" type="file">
            <address bus="1" controller="0" target="0" type="drive" unit="1"/>
            <source file="/var/run/vdsm/payload/50d99c82-2294-4f9b-aee0-8b76ae9e0468.2dcc1b3aaef33212283fc1f07fad9764.img" startupPolicy="optional"/>
            <target bus="ide" dev="hdd"/>
            <readonly/>
            <serial/>
        </disk>

please verify your system again

Comment 2 Michal Skrivanek 2014-04-14 10:47:20 UTC
ok, after further testing it seems that the payload is _not_ attached when using Run Once and a cdrom is defined in Run Once as well. Seems like no payload is sent when cloud-init is unchecked...correct behavior would be to send it when defined at VM properties level

need to check behavior with Windows sysprep+payload as well.

Comment 3 Artyom 2014-04-27 09:07:10 UTC
for windows vm exactly the same behavior, if I add floppy sysprep it visible as payload via REST

if I added payload cdrom via REST, and after it run once vm wit attached cdrom, in OS I can see just attached cdrom and payload not appear

Comment 4 Artyom 2014-04-27 09:08:01 UTC
Created attachment 890193 [details]
vdsm log with windows vm

Comment 5 Shahar Havivi 2014-04-27 10:23:00 UTC
(In reply to Artyom from comment #3)
The log indicate that you send the payload as floppy drive.
So if you are testing it via Linux os please try to load the floppy kernel drive first (its not loaded by default)
$ modprobe floppy

Comment 6 Artyom 2014-05-01 08:59:59 UTC
I talk about this with Shahar, and I said that behavior exist for cdrom payload,
when I add payload floppy and attach sysprep floppy so attach floppy replaced payload floppy(but Shahar said that for floppy it a behavior)

Comment 7 Michal Skrivanek 2014-05-02 09:31:42 UTC
Doesn't matter much for floppy, but cdrom…Shahar, I'm not entirely sure, but I think it is a regression from previous releases. With payload we used to attach two CDROMs I think…

@Artyom: is the behavior different if the CD is defined in VM properties and you do regular VM Run?

Comment 9 Artyom 2014-05-02 09:39:36 UTC
If I run regular run, vm have two cdroms, one payload and one attached from vm properties

Comment 10 Michal Skrivanek 2014-05-02 09:46:48 UTC
then it indeed needs a fix. The behavior of "Attach CD" in Run Once should be:
1) unchecked - no CD is sent, even not the one defined in VM properties
2) checked (UI pre-filled by default with the CD defined in properties) - exactly same behavior as regular Run VM
3) checked and custom CD is selected - replaces the one in properties or adds one if there is none defined.

as far as payload is concerned in all three cases there should be the payload CD attached as well, either standalone in case 1) or two CDs are attached in case 2) and 3)

Comment 11 Shahar Havivi 2014-05-07 08:57:34 UTC
Artyom,
When Checking this patch please verify that running with cd/paylaod (combined and separate) is the same as running via REST api.
Thanks!

Comment 13 Artyom 2014-07-14 09:11:37 UTC
Verified on ovirt-engine-3.5.0-0.0.master.20140629172257.git0b16ed7.el6.noarch

Comment 14 Omer Frenkel 2015-02-17 08:29:00 UTC
RHEV-M 3.5.0 has been released


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