Bug 1563721

Summary: Differencing Disk on Network Drive Fails Smartstate if initial disk on Local DRive.
Product: Red Hat CloudForms Management Engine Reporter: Satoe Imaishi <simaishi>
Component: SmartState AnalysisAssignee: Jerry Keselman <jkeselma>
Status: CLOSED ERRATA QA Contact: Satyajit Bulage <sbulage>
Severity: high Docs Contact:
Priority: high    
Version: 5.8.0CC: akarol, bsquizza, cpelland, jkeselma, obarenbo
Target Milestone: GAKeywords: ZStream
Target Release: 5.8.4   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 5.8.4.1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1547766 Environment:
Last Closed: 2018-06-25 14:19:13 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: CFME Core Target Upstream Version:
Embargoed:
Bug Depends On: 1547766    
Bug Blocks:    

Comment 2 CFME Bot 2018-04-09 22:31:42 UTC
New commit detected on ManageIQ/manageiq-gems-pending/fine:

https://github.com/ManageIQ/manageiq-gems-pending/commit/baed3c3b896a57e02183788851b2d327437ded34
commit baed3c3b896a57e02183788851b2d327437ded34
Author:     Richard Oliveri <oliveri.richard.github>
AuthorDate: Fri Feb 23 11:38:57 2018 -0500
Commit:     Richard Oliveri <oliveri.richard.github>
CommitDate: Fri Feb 23 11:38:57 2018 -0500

    Merge pull request #55 from jerryk55/get_drivetype_for_each_differencing_disk

    Check Drivetype for Each Differencing VhdxDisk
    (cherry picked from commit 5d71e56b703ba85f369dc145948377bbad6e8187)

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1563721

 lib/gems/pending/MiqVm/miq_scvmm_vm.rb | 1 +
 lib/gems/pending/disk/modules/VhdxDisk.rb | 3 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

Comment 9 Brandon Squizzato 2018-05-21 17:19:38 UTC
Verified on 5.8.4.3.20180515170411_29cc195


Set up a VM which uses a differencing disk as its boot disk, and the differencing disk points to a parent disk on a network share. Ran SSA against the VM.

I can see us calling .DriveType() to check if the disk is a network disk or not, and then using elevated access to read the VM's parent disk:

[----] D, [2018-05-21T12:54:01.040972 #7915:1143114] DEBUG -- : Running powershell script elevated on qeblade26.cfme-qe-vmm-ad.rhq.lab.eng.bos.redhat.com as CFME-QE-VMM-AD\Administrator: (Get-Item "\\scvmm2.cfme-qe-vmm-ad.rhq.lab.eng.bos.redhat.com\VMMLibrary\bsquizz-ws16\WS16DBase.vhdx").length

But non-elevated access on the local VM disk:
[----] D, [2018-05-21T12:53:56.697164 #7915:1143114] DEBUG -- : Running powershell script on qeblade26.cfme-qe-vmm-ad.rhq.lab.eng.bos.redhat.com as CFME-QE-VMM-AD\Administrator: $file_stream = [System.IO.File]::Open("C:\bsquizz-temp\newdiffdisk.vhdx", "Open", "Read", "Read")

Comment 11 errata-xmlrpc 2018-06-25 14:19:13 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.

https://access.redhat.com/errata/RHSA-2018:1972