Bug 1322902 - VMware provider doesn't report actual disk usage in VM details
Summary: VMware provider doesn't report actual disk usage in VM details
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Providers
Version: 5.5.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: GA
: 5.6.0
Assignee: Adam Grare
QA Contact: Satyajit Bulage
URL:
Whiteboard: smartstate:vmware
Depends On:
Blocks: 1310121 1326461
TreeView+ depends on / blocked
 
Reported: 2016-03-31 15:19 UTC by Christian Jung
Modified: 2019-11-14 07:42 UTC (History)
7 users (show)

Fixed In Version: 5.6.0.1
Doc Type: Bug Fix
Doc Text:
Previously, the "number of disks" field in the virtual machines area of the UI did not report disk usage statistics for VMware virtual machines. This occurred because of an error in the code which caused an exception during SmartState Analysis. This has been fixed in the code and virtual machine disk usage is now reported correctly.
Clone Of:
: 1326461 (view as bug list)
Environment:
Last Closed: 2016-06-29 15:46:46 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
used size for a virtual machine (14.81 KB, image/png)
2016-03-31 15:20 UTC, Christian Jung
no flags Details
used size for a template (14.94 KB, image/png)
2016-03-31 15:21 UTC, Christian Jung
no flags Details
ssa_used_size_works for vmware vm's (25.49 KB, image/png)
2016-04-25 22:33 UTC, amogh
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1348 0 normal SHIPPED_LIVE CFME 5.6.0 bug fixes and enhancement update 2016-06-29 18:50:04 UTC

Description Christian Jung 2016-03-31 15:19:57 UTC
Description of problem:
When navigating to a VM and then clicking on "Number of disks" to see the details, the usage is not reported.

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

How reproducible:
always on VMware

Steps to Reproduce:
1. add a VMware provider
2. run SSA for the VM and the data store (might not be necessary, but I wanted to make sure all data collection is executed)
3. navigate to a VM
4. click on "number of disks"

Actual results:
"Used size" is empty

Expected results:
Actual disk usage should be shown

Additional info:
I did test this also for templates and they do report the correct value for "used size"

Comment 2 Christian Jung 2016-03-31 15:20:45 UTC
Created attachment 1142273 [details]
used size for a virtual machine

reported value is empty

Comment 3 Christian Jung 2016-03-31 15:21:21 UTC
Created attachment 1142274 [details]
used size for a template

reported value is correct

Comment 6 Christian Jung 2016-04-07 09:38:22 UTC
HiHo,
in my lab there are only RHEL6 VMs and they all show the same (missing) information.

SSA works fine, as far as I can tell. It just doesn't show the correct "used size" in the details of the VM > Number of disks UI. 

I did run "InspectMe" for the VM and the template.
VM collected data:

[----] I, [2016-04-07T05:33:21.354349 #3080:1da8620]  INFO -- : <AEMethod inspectme>     Virtual Columns - disk_1_size: 5368709120
[----] I, [2016-04-07T05:33:21.357674 #3080:1da8620]  INFO -- : <AEMethod inspectme>     Virtual Columns - disk_1_size_on_disk: nil

Template collected data:
[----] I, [2016-04-07T05:34:15.480057 #3080:1daa3e4]  INFO -- : <AEMethod inspectme>     Virtual Columns - disk_1_size: 5368709120
[----] I, [2016-04-07T05:34:15.483523 #3080:1daa3e4]  INFO -- : <AEMethod inspectme>     Virtual Columns - disk_1_size_on_disk: 1289687040

For the VM "size on disk" is nil, but for the template it's the correct value.

I'll upload all logs and attach them to this ticket.

Regards,
Christian

Comment 9 CFME Bot 2016-04-11 17:20:41 UTC
New commit detected on ManageIQ/manageiq/master:
https://github.com/ManageIQ/manageiq/commit/75153c9146c0ca75e700247be52588dac1ed83cf

commit 75153c9146c0ca75e700247be52588dac1ed83cf
Author:     Adam Grare <agrare>
AuthorDate: Mon Apr 11 10:15:39 2016 -0400
Commit:     Adam Grare <agrare>
CommitDate: Mon Apr 11 10:30:08 2016 -0400

    Fix for used disk size not showing up on vms
    
    Fix a broken require which was throwing an exception when running
    SSA on a VM.  This caused no XML to be returned for the disks
    section of VmConfig, so the "Used Size" and "Partitions Aligned"
    were always empty for a VM.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1322902

 gems/pending/metadata/VmConfig/VmConfig.rb | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Comment 10 Adam Grare 2016-04-11 18:49:22 UTC
Root cause was a bad require causing a ruby LoadError in VmConfig#load_vim_snapshots.  SSA on templates worked because they bypassed this require because a snapshot is not required for SSA on a template.

Comment 15 amogh 2016-04-25 22:32:42 UTC
verified this bug in: 5.6.0.4-beta2.3.20160421172650_719e256 

disk usage is collected correctly for vm's on vmware providers. refer the screen shot "ssa_used_size_works"

steps followed:
configure the appliance for smart state analysism,by installing vddk and enabling "smart proxy".
1. add the vmware provider, add the credentials for provider and hosts.
2. run the ssa on any vm. wait for ssa to complete.  monitor evm.log
3. check the "number of disks" -> "used size" displayed correctly for the vm's. verified for RHEL 6 and Fedora 22 vm's.

Comment 16 amogh 2016-04-25 22:33:20 UTC
Created attachment 1150644 [details]
ssa_used_size_works for vmware vm's

Comment 18 errata-xmlrpc 2016-06-29 15:46:46 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/RHBA-2016:1348


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