Discrepancies between the Sub_Capacity values (PVU_SUB_CAP and PVU_FULL_CAP) returned from the REST API call 'api/sam/license_usages' and the ones returned by the audit_snapshot report (pvu_sub_capacity.csv)

HI Guys,

We have been struggling with this issue for quite some time now since we have started the importing of Sub_Capacity values via ILMT/BigFix REST API call ‘api/sam/license_usages’ for our customers.
I can’t expose the whole set of data from API and pvu_sub_capacity.csv (customer data) but here is a simple example for the product “IBM Business Monitor”
The API call ‘api/sam/license_usages’ is returning 11 unique rows while the pvu_sub_capacity.csv will return 8 rows.
Of the 11 rows returned by the ‘api/sam/license_usages’, only 03 rows have have values for both PVU_SUB_CAP and PVU_FULL_CAP. Rest of the 08 rows have incomplete capacity data.
On the other hand the 08 rows by the pvu_sub_capacity.csv is complete and have values for both PVU_SUB_CAP and PVU_FULL_CAP.
Both sources have only 03 rows in common.

Here are the sample data for the product “IBM Business Monitor”
Reponse from the REST API ‘api/sam/license_usages’
“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4036,“peak_value”:70,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4039,“peak_value”:70,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4050,“peak_value”:100,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4071,“peak_value”:70,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4223,“peak_value”:140,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_FULL_CAP”,“computer_system_id”:4525,“peak_value”:1120,“peak_date”:“2017-08-01”,“peak_time”:“2017-08-01T11:56:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}}
{“software_title_id”:9520,“metric_name”:“PVU_FULL_CAP”,“computer_system_id”:4578,“peak_value”:840,“peak_date”:“2017-08-01”,“peak_time”:“2017-08-01T11:56:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_FULL_CAP”,“computer_system_id”:4579,“peak_value”:840,“peak_date”:“2017-08-01”,“peak_time”:“2017-08-01T11:56:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_FULL_CAP”,“computer_system_id”:4719,“peak_value”:1120,“peak_date”:“2017-08-01”,“peak_time”:“2017-08-01T11:56:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4719,“peak_value”:140,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_FULL_CAP”,“computer_system_id”:4531,“peak_value”:1120,“peak_date”:“2017-08-01”,“peak_time”:“2017-08-01T11:56:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4531,“peak_value”:280,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_FULL_CAP”,“computer_system_id”:4539,“peak_value”:1120,“peak_date”:“2017-08-01”,“peak_time”:“2017-08-01T11:56:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},
{“software_title_id”:9520,“metric_name”:“PVU_SUB_CAP”,“computer_system_id”:4539,“peak_value”:560,“peak_date”:“2017-06-06”,“peak_time”:“2017-06-06T00:00:00Z”,“reporting_period_start_date”:“2017-05-31”,“reporting_period_end_date”:“2017-08-29”,“software_title_dimension”:{“name”:“IBM Business Monitor”,“guid”:“d29936f1-d4fa-4ede-848d-990864f7590c”,“publisher_name”:“IBM”,“publisher_guid”:“53e828a2-943f-48c8-8f66-1db82a0bf296”}},

**Data from the pvu_sub_capacity.csv for the same product

**

Does anyone know why we get such different set of data for these two sources and how to resolve this?

Any insight on this will be really appreciated

Thanks
Hameed

Take a look at this TechNote from IBM: Correct understanding of CSV version of PVU reports.

Yes, I understand that peak values can be varying and there could be differences in what we see from the ILMT/BigFix interface and what is returned by the CSV report.
Here, I am talking about the discrepancies in subCapacity PVU values between the SubCapacity report and what we get from the REST API call.
I have got the output for these two sets of data at the same time. So, it is very unlikely that we should be expecting so many discrepancies in the outputs.
My questions are:

  • Why am I getting the data for 11 hosts from the REST API call but only for 08 hosts via the Audit Snapshot report for the same product?
  • Only 03 hosts have the same SubCapacity values form both sources and the rest are dissimilar. Hard for me to understand this.
  • Should we not expect the same set of data from both sources (‘api/sam/license_usages’ and pvu_sub_capacity.csv for a given product? Or am I misunderstanding this?

Why am I getting the data for 11 hosts from the REST API call but only for 08 hosts via the Audit Snapshot report for the same product?

The REST API call returns full and subcapacity metrics for both computers (VMs) and hosts (VSphere, Hyper-V, KVM ), while the Audit Snapshot report returns subcapacity metrics for computers (VMs).

If you filter out the 6 rows of Full Capacity from the REST API results, you’ll get 8 computers with the “peak_value” data matching Column E, which is calculated from the number of processors assigned to each computer. Column D is calculated from the host cpu capacity, which represents the maximum possible PVUs. See below.

Only 03 hosts have the same SubCapacity values form both sources and the rest are dissimilar. Hard for me to understand this.

This is because Capacity Data is complete for these 3 computers. The other 5 entries represent computers where ILMT lacks VM Manager Data. Only the VM Manager knows which computers are running on which hosts. ILMT has to interrogate the VM Manager to tie it all together. You see this in the screen shot where the Server Name starts with TLM_VM, and in the REST API data where there is no Full Capacity data.

It looks like you need to add another VM Manager to ILMT.

Should we not expect the same set of data from both sources (‘api/sam/license_usages’ and pvu_sub_capacity.csv for a given product?

I think you are getting the same data from both sources.

Thanks
It is becoming much clearer now.
However I still have some unexplained points:
1- This means (as you said) if we filter out the the Pvu_Full_Cap rows from the REST API call, we will get only Pvu_Sub_Cap values on computers. Then how should we be getting the Pvu_SubCapacity_Limit (Column D) values from the API?
I am under the impression that Pvu_Full_Cap in API corresponds to Pvu_SubCapacity_Limit in pvu_sub-capacity report. Or is it not returned by the API?

Column D (Physical Server PVU Subcapacity Limit) is the peak value over the time period of the product report of the PVU_FULL_CAP metric of the physical server running one or more vms on which the product is installed. This value could change, if for instance, you added more CPUs or enabled any that were previously disabled.

Column E (Physical Server Subcapacity) is the peak value over the time period of the product report of the sum of PVU count of all the virtual machines running on that physical host. This value is affected by the migration of VMs, and the addition or removal of VMs.

ILMT must have access to the VM Manager of the physical host to retrieve the host capacity (number of processors) and which virtual machines are running on that host. If you are running a VMware environment, you would connect to the vCenter API of the computer that is used to managing your vSphere ESXi hosts.

Having complete capacity data is the only way the report or the API can return the correct values.

In your example, once you have complete capacity data, there may only be 4 rows of data, if all the orphan VMs are actually hosted on a single physical server (say, HP Server04, for instance). In this hypothetical example, Server04 may have a PVU Subcapacity Limit of 1120 (assuming 16 processors, the same as other servers in the report), and a PVU Subcapacity value of 420 (assuming the PVU per processor value of 70, the same as the other servers in the report).

Thanks for your explanation so far.

The ‘Incomplete virtualization hierarchy’ is a very common issue with most of our customers.
I have asked this particular customer for troubleshooting.
I will come back with my feedback once I have a fresh round of data pull from ‘api/sam/license_usages’.

Hi Again,

I am still getting some inconsistent values from the API 'License_Usages’
The “PVU_SUB_CAP” values are the same from both sources. But the “PVU_FULL_CAP” are not consistent. The ‘pvu_sub_capacity.CSV’ is showing the values for products
but the API is not populating the tag “PVU_FULL_CAP”, for these products. It is the case with some products, not all though. But still it will be wrong calculations towards the end. Let me know and I can post some example data for more elaboration if needed.
Can I rephrase my previous question?
Are we sure that the value “metric_name”: “PVU_FULL_CAP” from the REST API for a given product
corresponds to the column ‘Physical Server PVU Subcapacity Limit’ in the report 'pvu_sub_capacity.CSV?