Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1065719 - We can not know from the DB, if VMs running with run once are using an ISO file.
Summary: We can not know from the DB, if VMs running with run once are using an ISO file.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 3.4.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 3.5.0
Assignee: Martin Betak
QA Contact: Nikolai Sednev
URL:
Whiteboard: virt
Depends On:
Blocks: rhev3.5beta 1156165
TreeView+ depends on / blocked
 
Reported: 2014-02-16 09:44 UTC by Maor
Modified: 2015-02-17 12:00 UTC (History)
13 users (show)

Fixed In Version: ovirt-3.5.0-alpha1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-02-17 08:30:11 UTC
oVirt Team: ---
Target Upstream Version:


Attachments (Terms of Use)
engien log (deleted)
2014-02-16 09:44 UTC, Maor
no flags Details
vdsm log (deleted)
2014-02-17 12:26 UTC, Maor
no flags Details


Links
System ID Priority Status Summary Last Updated
oVirt gerrit 25585 None None None Never

Description Maor 2014-02-16 09:44:49 UTC
Created attachment 863678 [details]
engien log

Description of problem:
When starting a VM with run once and choose an ISO file, there is no indication in the DB which ISO file has been chosen to run with the VM.
That information is important when deactivating the ISO domain, so we can check if there are no VMs running with this ISO domain.

Version-Release number of selected component (if applicable):
3.4

How reproducible:
100%

Steps to Reproduce:
1.Create a VM
2.Use run once
3.Pick an ISO file to run with

Actual results:
No indication in the DB if an ISO file has been chosen.

Expected results:
The current_cd in vm_dynamic should be changed when the VM is starting up with the ISO selected in run once.

Additional info:

Comment 1 Omer Frenkel 2014-02-17 10:11:07 UTC
maor, can you run this on the host and share what returns for this vmId 
vdsClient 0 getVmStats <vmId> | grep cdrom

Comment 2 Maor 2014-02-17 10:19:57 UTC
(In reply to Omer Frenkel from comment #1)
> maor, can you run this on the host and share what returns for this vmId 
> vdsClient 0 getVmStats <vmId> | grep cdrom

no cdrom present.

vdsClient 0  getVmStats 3479c888-98f3-4d71-ad3b-b91f6082d889 | grep cdrom
doesn't return nothing.

[root@localhost ~]# vdsClient 0  getAllVmStats

3479c888-98f3-4d71-ad3b-b91f6082d889
        Status = Powering up
        username = Unknown
        memUsage = 0
        acpiEnable = true
        guestFQDN = 
        session = Unknown
        displaySecurePort = -1
        timeOffset = 0
        balloonInfo = {'balloon_max': '1048576', 'balloon_min': '1048576', 'balloon_target': '1048576', 'balloon_cur': '1048576'}
        pauseCode = NOERR
        network = {'vnet0': {'state': 'unknown', 'macAddr': '00:1a:4a:16:01:52', 'speed': '1000', 'name': 'vnet0'}}
        vmType = kvm
        cpuUser = 0.00
        elapsedTime = 2
        displayType = qxl
        cpuSys = 0.00
        appsList = []
        hash = 3608141519820207464
        pid = 4923
        displayIp = 0
        displayPort = 5900
        guestIPs = 
        kvmEnable = true
        disks = {'vda': {'truesize': '512', 'apparentsize': '1073741824', 'imageID': 'f97ffe51-171f-4df2-922e-ca48e6d8c09b'}, 'vdb': {'truesize': '512', 'apparentsize': '1073741824', 'imageID': '04835ce6-50f8-4a1a-920e-5598db180951'}, 'hdc': {'truesize': '0', 'apparentsize': '0'}}
        monitorResponse = 0
        statsAge = 2.01
        clientIp =

Comment 3 Omer Frenkel 2014-02-17 10:32:16 UTC
Maor, thanks! 
please attach also vdsm log for the host running this vm (make sure it includes the vmCreate call)

Martin, i thought this should be reported always?

Comment 4 Martin Betak 2014-02-17 10:42:57 UTC
Well, the vdsm reports the value that was passed in vmParams during creation of the VM or the latest "change cd" value (self.conf["cdrom"]). 
It may be the case the engine doesn't utilize this parameter when creating a RunOnce Vm.

Comment 5 Maor 2014-02-17 12:26:28 UTC
Created attachment 864076 [details]
vdsm log

Comment 6 Elad 2014-03-30 15:10:11 UTC
Need to check this scenario [1] again using Run-once, once this bug is fixed.



[1] https://bugzilla.redhat.com/show_bug.cgi?id=969641

Comment 7 Nikolai Sednev 2014-04-30 13:04:17 UTC
I'm getting these:
[root@rose01 ~]# vdsClient 0  getAllVmStats
Traceback (most recent call last):
  File "/usr/share/vdsm/vdsClient.py", line 2578, in <module>
  File "/usr/share/vdsm/vdsClient.py", line 442, in do_getAllVmStats
  File "/usr/lib64/python2.6/xmlrpclib.py", line 1199, in __call__
  File "/usr/lib64/python2.6/xmlrpclib.py", line 1489, in __request
  File "/usr/lib64/python2.6/xmlrpclib.py", line 1237, in request
  File "/usr/lib64/python2.6/httplib.py", line 1064, in getreply
  File "/usr/lib64/python2.6/httplib.py", line 990, in getresponse
  File "/usr/lib64/python2.6/httplib.py", line 391, in begin
  File "/usr/lib64/python2.6/httplib.py", line 349, in _read_status
  File "/usr/lib64/python2.6/socket.py", line 433, in readline
error: [Errno 104] Connection reset by peer


And these:

[root@rose01 ~]# vdsClient  -s 0 list table
76bda29f-741e-4183-99c6-2c3b9e0f737e   8781  test                 Up
[root@rose01 ~]# vdsClient 0 getVmStats 76bda29f-741e-4183-99c6-2c3b9e0f737e | grep cdrom
Traceback (most recent call last):
  File "/usr/share/vdsm/vdsClient.py", line 2578, in <module>
  File "/usr/share/vdsm/vdsClient.py", line 439, in do_getVmStats
  File "/usr/lib64/python2.6/xmlrpclib.py", line 1199, in __call__
  File "/usr/lib64/python2.6/xmlrpclib.py", line 1489, in __request
  File "/usr/lib64/python2.6/xmlrpclib.py", line 1237, in request
  File "/usr/lib64/python2.6/httplib.py", line 1064, in getreply
  File "/usr/lib64/python2.6/httplib.py", line 990, in getresponse
  File "/usr/lib64/python2.6/httplib.py", line 391, in begin
  File "/usr/lib64/python2.6/httplib.py", line 349, in _read_status
  File "/usr/lib64/python2.6/socket.py", line 433, in readline
error: [Errno 104] Connection reset by peer

Can you please review them and guide me what's wrong or missing?
It's not looks like OK to me.

Comment 8 Michal Skrivanek 2014-04-30 13:43:37 UTC
you're not running it with SSL, missing "-s"

Comment 9 Nikolai Sednev 2014-05-01 09:46:11 UTC
Looks like nothing is fixed?
Red Hat Enterprise Virtualization Manager Version: 3.4.0-0.16.rc.el6ev
[root@puma26 ~]# rpm -qa vdsm sanlock libvirt qemu*
qemu-kvm-rhev-tools-0.12.1.2-2.415.el6_5.9.x86_64
vdsm-4.14.7-0.2.rc.el6ev.x86_64
qemu-kvm-rhev-0.12.1.2-2.415.el6_5.9.x86_64
sanlock-2.8-1.el6.x86_64
qemu-img-rhev-0.12.1.2-2.415.el6_5.9.x86_64
libvirt-0.10.2-29.el6_5.7.x86_64



[root@puma26 ~]# vdsClient -s 0 getVmStats 76bda29f-741e-4183-99c6-2c3b9e0f737e | grep cdrom

nothing received.


[root@puma26 ~]# vdsClient -s 0 getVmStats 76bda29f-741e-4183-99c6-2c3b9e0f737e 

76bda29f-741e-4183-99c6-2c3b9e0f737e
        Status = Up                 
        username = Unknown          
        memUsage = 0                
        acpiEnable = true           
        guestFQDN =                 
        session = Unknown           
        displaySecurePort = 5901    
        timeOffset = 0              
        balloonInfo = {'balloon_max': '1048576', 'balloon_min': '1048576', 'balloon_target': '1048576', 'balloon_cur': '1048576'}
        pauseCode = NOERR                                                                                                        
        network = {'vnet0': {'macAddr': '00:1a:4a:a5:fb:8c', 'rxDropped': '0', 'txDropped': '0', 'rxErrors': '0', 'txRate': '0.0', 'rxRate': '0.0', 'txErrors': '0', 'state': 'unknown', 'speed': '1000', 'name': 'vnet0'}}
        vmType = kvm
        cpuUser = 0.25
        elapsedTime = 539
        displayType = qxl
        cpuSys = 0.80
        appsList = []
        hash = 7723132712028165560
        pid = 5162
        displayIp = 0
        displayPort = 5900
        guestIPs =
        kvmEnable = true
        disks = {'vda': {'readLatency': '0', 'apparentsize': '16106127360', 'writeLatency': '0', 'imageID': 'fde672bc-9f13-4b43-a811-ef0571ed8e5d', 'flushLatency': '0', 'readRate': '0.00', 'truesize': '24576', 'writeRate': '0.00'}, 'hdc': {'readLatency': '0', 'apparentsize': '0', 'writeLatency': '0', 'flushLatency': '0', 'readRate': '0.00', 'truesize': '0', 'writeRate': '0.00'}}
        monitorResponse = 0
        statsAge = 1.75
        guestCPUCount = -1
        clientIp =

Comment 10 Michal Skrivanek 2014-05-02 10:10:54 UTC
Nikolai, sorry, this apparently wasn't fixed in 3.4 at all.
Martin, this was not backported to 3.4 so why did you move it to MODIFIED?

I propose deferring this to 3.5 then as we're too close to 3.4 GA

Comment 11 Nikolai Sednev 2014-05-22 08:17:10 UTC
Please provide relevant repository path towards the build.

Comment 12 Michal Skrivanek 2014-05-22 10:32:24 UTC
http://www.ovirt.org/OVirt_3.5_Release_Notes

Comment 13 Nikolai Sednev 2014-08-14 12:44:44 UTC
I'm sorry, but not getting anything for VM CDROM being inserted:
[root@master-vds10 ~]# vdsClient -s 0 getVmStats 28734afc-a37f-467b-bde3-1bd41ef0a6dc | grep cdrom                               
[root@master-vds10 ~]# clear                                                                                                     
[root@master-vds10 ~]# vdsClient -s 0 getVmStats 28734afc-a37f-467b-bde3-1bd41ef0a6dc 

28734afc-a37f-467b-bde3-1bd41ef0a6dc
        Status = Up                 
        displayInfo = [{'tlsPort': '5902', 'ipAddress': '10.35.64.85', 'port': '5901', 'type': 'spice'}]
        memUsage = 0                                                                                    
        acpiEnable = true
        session = Unknown
        displaySecurePort = 5902
        timeOffset = 0
        balloonInfo = {'balloon_max': '1048576', 'balloon_min': '1048576', 'balloon_target': '0', 'balloon_cur': '1048576'}
        pauseCode = NOERR
        network = {'vnet1': {'macAddr': '00:01:a4:af:10:02', 'rxDropped': '0', 'txDropped': '0', 'rxErrors': '0', 'txRate': '0.0', 'rxRate': '0.0', 'txErrors': '0', 'state': 'unknown', 'speed': '1000', 'name': 'vnet1'}}
        vmType = kvm
        cpuUser = 0.52
        elapsedTime = 2366
        vmJobs = {}
        cpuSys = 0.67
        appsList = []
        displayType = qxl
        guestFQDN =
        hash = -4717464242162679042
        pid = 20913
        displayIp = 10.35.64.85
        vcpuPeriod = 100000
        displayPort = 5901
        guestIPs =
        vcpuQuota = -1
        kvmEnable = true
        disks = {'vda': {'readLatency': '0', 'apparentsize': '16106127360', 'writeLatency': '0', 'imageID': 'a78e4701-dca3-4e0b-82c0-a43028319cd6', 'flushLatency': '0', 'readRate': '0.00', 'truesize': '16106127360', 'writeRate': '0.00'}, 'hdd': {'readLatency': '0', 'apparentsize': '0', 'writeLatency': '0', 'flushLatency': '0', 'readRate': '0.00', 'truesize': '0', 'writeRate': '0.00'}, 'hdc': {'readLatency': '0', 'apparentsize': '0', 'writeLatency': '0', 'flushLatency': '0', 'readRate': '0.00', 'truesize': '0', 'writeRate': '0.00'}}
        monitorResponse = 0
        statsAge = 1.54
        username = Unknown
        guestCPUCount = -1
        vcpuCount = 1
        clientIp = 10.36.5.219

[root@master-vds10 ~]# vdsClient -s 0 getVmStats 28734afc-a37f-467b-bde3-1bd41ef0a6dc | grep cdrom


Nothing received for cdrom.

Comment 14 Nikolai Sednev 2014-08-14 12:46:47 UTC
Components:
Linux version 2.6.32-431.23.3.el6.x86_64 (mockbuild@x86-027.build.eng.bos.redhat.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-4) (GCC) ) #1 SMP Wed Jul 16 06:12:23 EDT 2014

libvirt-0.10.2-29.el6_5.10.x86_64
sanlock-2.8-1.el6.x86_64
vdsm-4.16.1-6.gita4a4614.el6.x86_64
qemu-kvm-rhev-0.12.1.2-2.415.el6_5.14.x86_64


ovirt-engine-setup-3.5.0-0.0.master.20140804172041.git23b558e.el6.noarch

Comment 15 Martin Betak 2014-08-14 13:09:41 UTC
Nikolai: please disregard the output of the vdsClient, its output is not supported. Regardless of that we store the information about current cd in the engine database (vm_dynamic table, column current_cd). If you want to see the current CD please use the following REST request: 
GET /ovirt-engine/api/vms/<vm_id>/cdroms;current 
or in the webadmin UI press "Change CD" and the current should be preselected.

Comment 16 Nikolai Sednev 2014-08-14 14:22:26 UTC
Pass:
<cdroms>
<cdrom href= "/ovirt-engine/api/vms/28734afc-a37f-467b-bde3-1bd41ef0a6dc/cdroms/00000000-0000-0000-0000-000000000000" id="00000000-0000-0000-0000-000000000000">
<vm href= "/ovirt-engine/api/vms/28734afc-a37f-467b-bde3-1bd41ef0a6dc" id="28734afc-a37f-467b-bde3-1bd41ef0a6dc"/>
<file id="Fedora-20-x86_64-DVD.iso"/>
</cdrom>
</cdroms>

Comment 17 Omer Frenkel 2015-02-17 08:30:11 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.