Bug 1564996 - Start VM with direct LUN attached with SCSI Pass-Through enabled fails on libvirtError [rhel-7.5.z]
Summary: Start VM with direct LUN attached with SCSI Pass-Through enabled fails on lib...
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libvirt
Version: 7.5
Hardware: x86_64
OS: Unspecified
Target Milestone: rc
: ---
Assignee: Michal Privoznik
QA Contact: yisun
Depends On: 1557769
Blocks: 1568441
TreeView+ depends on / blocked
Reported: 2018-04-09 06:33 UTC by Oneata Mircea Teodor
Modified: 2021-01-18 14:06 UTC (History)
31 users (show)

Fixed In Version: libvirt-3.9.0-14.el7_5.3
Doc Type: Bug Fix
Doc Text:
In Red Hat Enterprise Linux 7.5, guests with SCSI passthrough enabled failed to boot because of changes in kernel CGroup detection. With this update, libvirt fetches dependencies and adds them to the device CGroup. As a result, and the affected guests now start as expected.
Clone Of: 1557769
Last Closed: 2018-05-14 16:11:44 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Article) 3401221 0 None None None 2018-04-09 06:33:56 UTC
Red Hat Product Errata RHSA-2018:1396 0 None None None 2018-05-14 16:13:02 UTC

Description Oneata Mircea Teodor 2018-04-09 06:33:27 UTC
This bug has been copied from bug #1557769 and has been proposed to be backported to 7.5 z-stream (EUS).

Comment 6 yisun 2018-04-16 07:58:45 UTC
Verified on:

1. start vm with multipath device
# multipath -ll
mpathb (360050763008084e6e000000000000064) dm-2 IBM     ,2145            
size=20G features='1 queue_if_no_path' hwhandler='0' wp=rw
|-+- policy='service-time 0' prio=50 status=active
| `- 8:0:1:1 sde 8:64 active ready running
`-+- policy='service-time 0' prio=10 status=enabled
  `- 8:0:0:1 sdc 8:32 active ready running

# virsh dumpxml vm | grep "<disk" -A7
    <disk type='block' device='lun' sgio='filtered' snapshot='no'>
      <driver name='qemu' type='raw' cache='none' error_policy='stop' io='native'/>
      <source dev='/dev/mapper/mpathb'/>
      <target dev='sda' bus='scsi'/>
      <boot order='1'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>

# virsh domblklist vm
Target     Source
sda        /dev/mapper/mpathb

# virsh start vm
Domain vm started

# virsh list
 Id    Name                           State
 18    vm                             running

2. hot plug a multipath device
# virsh start vm
vDomain vm started

# virsh domblklist vm
Target     Source
vda        /var/lib/avocado/data/avocado-vt/images/RHEL-7.5-x86_64-latest.qcow2

# cat mpath.xml 
    <disk type='block' device='lun' sgio='filtered' snapshot='no'>
      <driver name='qemu' type='raw' cache='none' error_policy='stop' io='native'/>
      <source dev='/dev/mapper/mpathb'/>
      <target dev='sda' bus='scsi'/>

# virsh attach-device vm mpath.xml 
Device attached successfully

# virsh domblklist vm
Target     Source
vda        /var/lib/avocado/data/avocado-vt/images/RHEL-7.5-x86_64-latest.qcow2
sda        /dev/mapper/mpathb

Comment 7 yisun 2018-04-16 10:33:54 UTC
Hi Elad,
This bug was verified in pure libvirt env. Pls judge if you need to run some auto cases from rhev's perspective to cover some other risk area. thx

Comment 8 Elad 2018-04-17 14:05:51 UTC
This will be tested once Bug 1568441 is ON_QA

Comment 9 Yaniv Kaul 2018-04-17 19:59:38 UTC
(In reply to Elad from comment #8)
> This will be tested once Bug 1568441 is ON_QA

Why not just take the fixed image and test it? Why should we add a dependency, if it may end up not working?

Comment 10 Elad 2018-04-18 09:06:04 UTC
Tested tier1 direct LUN automation with the qemu-kvm-rhev build from [1].

1. Create a VM with a direct LUN attached (tested with SCSI Pass-Through as enabled and as disabled)
2. Start the VM

Start VM succeeded.

With SCSI passthough enabled:

2018-04-18 11:55:46,601+0300 INFO  (jsonrpc/7) [api.virt] FINISH create return={'status': {'message': 'Done', 'code': 0}, 'vmList'
<disk snapshot="no" type="block" device="disk"><target dev="vda" bus="virtio"></target><source dev="/rhev/data-center/mnt/blockSD/3c8aaba0-ceec-44fd-8a8e-c375a1c7d692/images/a8395c4e-a15d-4c2a-b07a-fe9958328d5c/a6543775-e0f3-4b9e-9676-9408f381170b"></source><driver name="qemu" io="native" type="qcow2" error_policy="stop" cache="none"></driver><alias name="ua-a8395c4e-a15d-4c2a-b07a-fe9958328d5c"></alias><address bus="0x00" domain="0x0000" function="0x0" slot="0x07" type="pci"></address><boot order="1"></boot><serial>a8395c4e-a15d-4c2a-b07a-fe9958328d5c</serial></disk><disk snapshot="no" type="block" device="lun" sgio="unfiltered"><target dev="sda" bus="scsi"></target><source dev="/dev/mapper/3514f0c5a516008d7"></source><driver name="qemu" io="native" type="raw" error_policy="stop" cache="none"></driver><alias name="ua-66100ab8-21bc-4e65-be8b-d14acb074163"></alias><address bus="0" controller="0" unit="0" type="drive" target="0">

2018-04-18 11:55:46,605+0300 INFO  (jsonrpc/7) [jsonrpc.JsonRpcServer] RPC call VM.create succeeded in 0.06 seconds (__init__:573)


kernel - 3.10.0-862.el7.x86_64

Comment 14 errata-xmlrpc 2018-05-14 16:11:44 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


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