Bug 1771469

Summary: Hot-plug SATA disk from VM fails with error - Validation of action 'HotPlugDiskToVm' failed for user admin@internal-authz. Reasons: VAR__ACTION__HOT_PLUG,VAR__TYPE__DISK,ACTION_TYPE_DISK_INTERFACE_UNSUPPORTED,$osName Other OS
Product: [oVirt] ovirt-engine Reporter: Avihai <aefrat>
Component: BLL.StorageAssignee: Shmuel Melamud <smelamud>
Status: CLOSED NOTABUG QA Contact: Evelina Shames <eshames>
Severity: high Docs Contact:
Priority: high    
Version: 4.4.0CC: ahadas, bugs, michal.skrivanek, mtessun, sfishbai
Target Milestone: ovirt-4.4.2Flags: pm-rhel: ovirt-4.4+
mtessun: planning_ack+
ahadas: devel_ack+
sfishbai: testing_ack+
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-08-17 16:53:41 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Virt RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
engine and vdsm logs
none
engine-log none

Description Avihai 2019-11-12 12:37:04 UTC
Created attachment 1635334 [details]
engine and vdsm logs

Description of problem:
hot plug(VM is up) disk with interface=SATA fails.
This can be by creating a new SATA disk or attaching an existing SATA disk.

Engine:
2019-11-12 14:04:41,157+02 WARN  [org.ovirt.engine.core.bll.storage.disk.HotPlugDiskToVmCommand] (EE-ManagedThreadFactory-engineScheduled-Thread-46) [50bb840b] Validation of action 'HotPlugDiskToVm' failed for user admin@internal-authz. Reasons: VAR__ACTION__HOT_PLUG,VAR__TYPE__DISK,ACTION_TYPE_DISK_INTERFACE_UNSUPPORTED,$osName Other OS
2019-11-12 14:04:41,199+02 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (EE-ManagedThreadFactory-engineScheduled-Thread-46) [50bb840b] EVENT_ID: USER_FAILED_HOTPLUG_DISK(2,001), 
Failed to plug disk vm_test1_Disk1 to VM vm_test1 (User: admin@internal-authz).

VDSM:
2019-11-12 14:04:33,493+0200 INFO  (jsonrpc/1) [vdsm.api] START createVolume(sdUUID='45f2708d-4b6d-418d-aaf1-10bea1b94552', spUUID='c6458a6b-4bc5-4af7-a155-a34a71f310f4', imgUUID='f22dbef3-6448-4c73-a54d-3295ea8dd9c0', size='1073741824', volFormat=5, preallocate=1, diskType='DATA', volUUID='8e93d226-334f-4829-9e2d-5fddb550d726', desc='{"DiskAlias":"vm_test1_Disk1","DiskDescription":""}', srcImgUUID='00000000-0000-0000-0000-000000000000', srcVolUUID='00000000-0000-0000-0000-000000000000', initialSize=None) from=::ffff:10.35.161.118,50480, flow_id=99e5d044-075f-4566-88fc-105118c45a56, task_id=78a16fab-d752-46a0-b04e-7c4a91ca8946 (api:48)
2019-11-12 14:04:33,933+0200 INFO  (tasks/0) [storage.StorageDomain] Create placeholder /rhev/data-center/mnt/blockSD/45f2708d-4b6d-418d-aaf1-10bea1b94552/images/f22dbef3-6448-4c73-a54d-3295ea8dd9c0 for image's volumes (sd:1400)
2019-11-12 14:04:35,044+0200 INFO  (tasks/0) [storage.Volume] Creating volume symlink from '/dev/45f2708d-4b6d-418d-aaf1-10bea1b94552/8e93d226-334f-4829-9e2d-5fddb550d726' to '/rhev/data-center/mnt/blockSD/45f2708d-4b6d-418d-aaf1-10bea1b94552/images/f22dbef3-6448-4c73-a54d-3295ea8dd9c0/8e93d226-334f-4829-9e2d-5fddb550d726' (blockVolume:503)
2019-11-12 14:04:35,044+0200 INFO  (tasks/0) [storage.Volume] Request to create RAW volume /rhev/data-center/mnt/blockSD/45f2708d-4b6d-418d-aaf1-10bea1b94552/images/f22dbef3-6448-4c73-a54d-3295ea8dd9c0/8e93d226-334f-4829-9e2d-5fddb550d726 with capacity = 1073741824 (blockVolume:508)
2019-11-12 14:04:35,538+0200 INFO  (tasks/0) [storage.LVM] Change LV tags (vg=45f2708d-4b6d-418d-aaf1-10bea1b94552, lv=8e93d226-334f-4829-9e2d-5fddb550d726, delTags=['OVIRT_VOL_INITIALIZING'], addTags=['MD_11', 'PU_00000000-0000-0000-0000-000000000000', 'IU_f22dbef3-6448-4c73-a54d-3295ea8dd9c0']) (lvm:1517)
2019-11-12 14:04:41,231+0200 INFO  (jsonrpc/1) [vdsm.api] START getVolumeInfo(sdUUID='45f2708d-4b6d-418d-aaf1-10bea1b94552', spUUID='c6458a6b-4bc5-4af7-a155-a34a71f310f4', imgUUID='f22dbef3-6448-4c73-a54d-3295ea8dd9c0', volUUID='8e93d226-334f-4829-9e2d-5fddb550d726', options=None) from=::ffff:10.35.161.118,50462, flow_id=99e5d044-075f-4566-88fc-105118c45a56, task_id=d70d3771-0804-4810-936a-1ec50f08a84d (api:48)
2019-11-12 14:04:41,234+0200 INFO  (jsonrpc/1) [storage.VolumeManifest] Info request: sdUUID=45f2708d-4b6d-418d-aaf1-10bea1b94552 imgUUID=f22dbef3-6448-4c73-a54d-3295ea8dd9c0 volUUID = 8e93d226-334f-4829-9e2d-5fddb550d726  (volume:238)
2019-11-12 14:04:41,283+0200 INFO  (jsonrpc/1) [storage.VolumeManifest] 45f2708d-4b6d-418d-aaf1-10bea1b94552/f22dbef3-6448-4c73-a54d-3295ea8dd9c0/8e93d226-334f-4829-9e2d-5fddb550d726 info is {'uuid': '8e93d226-334f-4829-9e2d-5fddb550d726', 'type': 'PREALLOCATED', 'format': 'RAW', 'disktype': 'DATA', 'voltype': 'LEAF', 'capacity': '1073741824', 'parent': '00000000-0000-0000-0000-000000000000', 'description': '{"DiskAlias":"vm_test1_Disk1","DiskDescription":""}', 'pool': '', 'domain': '45f2708d-4b6d-418d-aaf1-10bea1b94552', 'image': 'f22dbef3-6448-4c73-a54d-3295ea8dd9c0', 'ctime': '1573560277', 'mtime': '0', 'legality': 'LEGAL', 'generation': 0, 'apparentsize': '1073741824', 'truesize': '1073741824', 'status': 'OK', 'lease': {'path': '/dev/45f2708d-4b6d-418d-aaf1-10bea1b94552/leases', 'offset': 116391936, 'owners': [], 'version': None}, 'children': []} (volume:277)
2019-11-12 14:04:41,283+0200 INFO  (jsonrpc/1) [vdsm.api] FINISH getVolumeInfo return={'info': {'uuid': '8e93d226-334f-4829-9e2d-5fddb550d726', 'type': 'PREALLOCATED', 'format': 'RAW', 'disktype': 'DATA', 'voltype': 'LEAF', 'capacity': '1073741824', 'parent': '00000000-0000-0000-0000-000000000000', 'description': '{"DiskAlias":"vm_test1_Disk1","DiskDescription":""}', 'pool': '', 'domain': '45f2708d-4b6d-418d-aaf1-10bea1b94552', 'image': 'f22dbef3-6448-4c73-a54d-3295ea8dd9c0', 'ctime': '1573560277', 'mtime': '0', 'legality': 'LEGAL', 'generation': 0, 'apparentsize': '1073741824', 'truesize': '1073741824', 'status': 'OK', 'lease': {'path': '/dev/45f2708d-4b6d-418d-aaf1-10bea1b94552/leases', 'offset': 116391936, 'owners': [], 'version': None}, 'children': []}} from=::ffff:10.35.161.118,50462, flow_id=99e5d044-075f-4566-88fc-105118c45a56, task_id=d70d3771-0804-4810-936a-1ec50f08a84d (api:54)


Version-Release number of selected component (if applicable):
ovirt-engine-tools-4.4.0-0.4.master.el7.noarch
vdsm-4.40.0-127.gitc628cce.el8ev.x86_64
libvirt-client-5.0.0-12.module+el8.0.1+3755+6782b0ed.x86_64
qemu-guest-agent-2.12.0-3.el7.x86_64
qemu-kvm-3.1.0-30.module+el8.0.1+3755+6782b0ed.x86_64

How reproducible:
100%

Steps to Reproduce:
1.Start a VM with OS(RHEL8.0)
2.Create a new disk with SATA interface type or attach an exising disk with SATA interface type 

Actual results:
hot plug(VM is up) disk with interface=SATA fails

Expected results:
hot plug(VM is up) disk with interface=SATA should work.

Additional info:
No issue doing the same add SATA disk when the VM is down.
This only occurs when VM is UP.

Comment 1 Michal Skrivanek 2019-11-13 06:11:07 UTC
SATA is missing in hotpluggableInterfaces osinfo

Comment 2 Evelina Shames 2020-08-11 12:04:33 UTC
Fails on engine-4.4.2.1-0.15:
2020-08-11 15:02:49,322+03 ERROR [org.ovirt.engine.core.bll.storage.disk.HotPlugDiskToVmCommand] (EE-ManagedThreadFactory-engine-Thread-5949) [42762be2-3922-4213-b8f8-706c4b3af7c3] Command 'org.ovirt.engine.core.bll.storage.disk.HotPlugDiskToVmCommand' failed: EngineException: org.ovirt.engine.core.vdsbroker.vdsbroker.VDSErrorException: VDSGenericException: VDSErrorException: Failed to HotPlugDiskVDS, error = Operation not supported: disk bus 'sata' cannot be hotplugged., code = 45 (Failed with error FailedToPlugDisk and code 45)

Attaching engine log.

Comment 3 RHEL Program Management 2020-08-11 12:04:42 UTC
Target release should be placed once a package build is known to fix a issue. Since this bug is not modified, the target version has been reset. Please use target milestone to plan a fix for a oVirt release.

Comment 4 Evelina Shames 2020-08-11 12:07:35 UTC
Created attachment 1711074 [details]
engine-log

Comment 5 Arik 2020-08-17 16:53:41 UTC
Disks hot-plug is (intentionally) disabled for SATA interface by the underlying platform and therefore that should fail with validation error on our side.