<h2>[CMP\AWS Susbscription Allocation] Abrupt licensing count for AWS in the Subscription Allocation Report</h2><br/><div style="overflow-x:auto"><div><h3>Description</h3><ul style="list-style-position: inside;"><li>It has been noted that there is an unusual licensing count on the Subscription Allocation Report overview for Cloud Management - Node. It displays "Allocated" over and above the "Purchased".</li></ul> <p style="padding-left: 40px;"><img style="align: baseline;" src="sys_attachment.do?sys_id=66c70293db228094d82ffb24399619e7" width="1050" height="350" align="baseline" /></p> <ul style="list-style-position: inside;"><li>This article explains how the Allocated rights show more than the Purchased rights and from where the data is being pulled.</li></ul></div><div><h3>Release or Environment</h3><ul style="list-style-position: inside;"><li>Instance with CMP plugin enabled.</li></ul></div><div><h3>Resolution</h3><ul style="list-style-position: inside;"><li>The data populated in Subscription Allocation Report is being pulled based on the below scripts:</li></ul> <p style="padding-left: 80px;">1. The following script <span style="color: blue;">"CMP_Provisioned_VM_Count" </span>which gets the VM from table "ldc_hosted_vm_instance" and calculates the count of VM. This VM count is then multiplied by 0.5 and updated in table "usageanalytics_count". (here the VM's which are in "On", "Off" & "Suspended" states will be used for calculation and not in the "deprovisioned" state)</p> <pre style="padding-left: 40px;">https://<<instance_name>>.service-now.com/nav_to.do?uri=usageanalytics_count_cfg.do?sys_id=cb5bcd58db8c27003fcbe1d3ca9619c5</pre> <p style="padding-left: 80px;">2. The following script <span style="color: blue;">"CMPDailyProvisionedVMAverageCount"</span> which takes average data (i.e. data from CMP_Provisioned_VM_Count in usageanalytics_count table) for last 365 days and updates the Used i.e. Allocated count for "Cloud Management - Node" in the Subscription Management dashboard.</p> <pre style="padding-left: 40px;">https://<<instance_name>>.service-now.com/nav_to.do?uri=usageanalytics_count_cfg.do?sys_id=31932931db042b003fcbe1d3ca961923</pre> <ul style="list-style-position: inside;"><li>Below 2 scripts which are attached can be executed using the Background Scripts to get Total count license and VM used for License.</li></ul> <p style="padding-left: 80px;">1. <strong>TotalCountLicense.txt</strong> - This script will help you to get the count populated in <span style="color: #0000ff;">CMP_Provisioned_VM_Count</span>.</p> <p style="padding-left: 80px;">2. <strong>VMusedForLicense.txt</strong> - This script will return the "VM names" and their "sysID" which are being used for license count.</p></div></div>