Bug 1057546 - vdsm: cannot start a vm in read only with IDE disk type
Summary: vdsm: cannot start a vm in read only with IDE disk type
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: oVirt
Classification: Retired
Component: vdsm
Version: unspecified
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
: 3.4.0
Assignee: Sergey Gotliv
QA Contact: Aharon Canan
URL:
Whiteboard: storage
Depends On:
Blocks: 1057969
TreeView+ depends on / blocked
 
Reported: 2014-01-24 10:24 UTC by Dafna Ron
Modified: 2016-02-10 18:59 UTC (History)
7 users (show)

Fixed In Version: ovirt-3.4.0-beta3
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1057969 (view as bug list)
Environment:
Last Closed: 2014-03-31 12:30:25 UTC
oVirt Team: Storage


Attachments (Terms of Use)
logs (506.55 KB, application/x-gzip)
2014-01-24 10:24 UTC, Dafna Ron
no flags Details


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 23953 0 None None None Never
oVirt gerrit 23998 0 None None None Never
oVirt gerrit 24258 0 None None None Never
oVirt gerrit 24259 0 None None None Never

Description Dafna Ron 2014-01-24 10:24:36 UTC
Created attachment 854874 [details]
logs

Description of problem:

we cannot start a vm with IDE disk+read-only. 

This looks like it might fail in libvirt. 

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

[root@cougar06 ~]# rpm -qa |grep libvirt 
libvirt-client-0.10.2-29.el6.1.x86_64
libvirt-0.10.2-29.el6.1.x86_64
libvirt-lock-sanlock-0.10.2-29.el6.1.x86_64
libvirt-python-0.10.2-29.el6.1.x86_64
[root@cougar06 ~]# rpm -qa |grep vdsm
vdsm-4.14.1-2.el6.x86_64
vdsm-python-4.14.1-2.el6.x86_64
vdsm-cli-4.14.1-2.el6.noarch
vdsm-python-zombiereaper-4.14.1-2.el6.noarch
vdsm-xmlrpc-4.14.1-2.el6.noarch
[root@cougar06 ~]# rpm -qa |grep qemu
qemu-img-rhev-0.12.1.2-2.415.el6.3.x86_64
gpxe-roms-qemu-0.9.7-6.10.el6.noarch
qemu-kvm-rhev-tools-0.12.1.2-2.415.el6.3.x86_64
qemu-kvm-rhev-0.12.1.2-2.415.el6.3.x86_64
[root@cougar06 ~]# 


How reproducible:

100%

Steps to Reproduce:
1. create a vm with IDE disk and read-only
2. start it
3. 

Actual results:

we fail to start the vm

Expected results:

we should either fail in Engine with CanDoAction or support this. 

Additional info:

Thread-37694::ERROR::2014-01-24 12:16:02,114::vm::2273::vm.Vm::(_startUnderlyingVm) vmId=`a895a0db-e35a-47a5-b019-9ebfc0033545`::The vm start process failed
Traceback (most recent call last):
  File "/usr/share/vdsm/vm.py", line 2233, in _startUnderlyingVm
    self._run()
  File "/usr/share/vdsm/vm.py", line 3164, in _run
    self._connection.createXML(domxml, flags),
  File "/usr/lib64/python2.6/site-packages/vdsm/libvirtconnection.py", line 92, in wrapper
    ret = f(*args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/libvirt.py", line 2665, in createXML
    if ret is None:raise libvirtError('virDomainCreateXML() failed', conn=self)
libvirtError: internal error process exited while connecting to monitor: qemu-kvm: -device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1: Can't use a read-only drive
qemu-kvm: -device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1: Device 'ide-drive' could not be initialized



.SimpleLogAdapter instance at 0x7fa9fc1507e8> name:hdc networkDev:False path: readonly:true reqsize:0 serial: shared:false specParams:{'path': ''} transientDisk:False truesize:0 type:disk volExtensionChunk:1024 watermarkLimit:536870912
Traceback (most recent call last):
  File "/usr/share/vdsm/clientIF.py", line 326, in teardownVolumePath
    res = self.irs.teardownImage(drive['domainID'],
  File "/usr/share/vdsm/vm.py", line 1493, in __getitem__
    raise KeyError(key)
KeyError: 'domainID'
Thread-37770::INFO::2014-01-24 12:17:54,287::logUtils::44::dispatcher::(wrapper) Run and protect: teardownImage(sdUUID='be5731ac-ce60-4302-ab04-99573f6799e4', spUUID='6fe33247-68e1-4e46-be2a-ab90ab4384e3', imgUUID='76297de9-4ac8-4822-b1df-58dbc36da7b6', volUUID=None)
Thread-37770::INFO::2014-01-24 12:17:54,288::logUtils::47::dispatcher::(wrapper) Run and protect: teardownImage, Return response: None
Thread-37770::INFO::2014-01-24 12:17:54,291::logUtils::44::dispatcher::(wrapper) Run and protect: inappropriateDevices(thiefId='a895a0db-e35a-47a5-b019-9ebfc0033545')
Thread-37770::INFO::2014-01-24 12:17:54,300::logUtils::47::dispatcher::(wrapper) Run and protect: inappropriateDevices, Return response: None
Thread-37770::DEBUG::2014-01-24 12:17:54,300::vm::4609::vm.Vm::(deleteVm) vmId=`a895a0db-e35a-47a5-b019-9ebfc0033545`::Total desktops after destroy of a895a0db-e35a-47a5-b019-9ebfc0033545 is 0
Thread-37770::DEBUG::2014-01-24 12:17:54,301::BindingXMLRPC::977::vds::(wrapper) return vmDestroy with {'status': {'message': 'Machine destroyed', 'code': 0}

Comment 1 Itamar Heim 2014-01-26 08:11:11 UTC
Setting target release to current version for consideration and review. please
do not push non-RFE bugs to an undefined target release to make sure bugs are
reviewed for relevancy, fix, closure, etc.

Comment 2 Sandro Bonazzola 2014-02-19 12:27:12 UTC
This bug is referenced in ovirt-engine-3.4.0-beta3 logs. Moving to ON_QA

Comment 3 Leonid Natapov 2014-02-19 15:10:26 UTC
tested on 3.4.0-0.11.beta3.el6. IDE disk can not be read only. It blocked by UI and backend.

Comment 4 Sandro Bonazzola 2014-03-31 12:30:25 UTC
this is an automated message: moving to Closed CURRENT RELEASE since oVirt 3.4.0 has been released


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