<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Unable to retrieve performance metric for a vm in VMware{code} Discussions</title>
    <link>https://communities.vmware.com/t5/VMware-code-Discussions/Unable-to-retrieve-performance-metric-for-a-vm/m-p/2975369#M2284</link>
    <description>&lt;P&gt;Same here! &lt;img class="lia-deferred-image lia-image-emoji" src="https://communities.vmware.com/html/@8D3AC78033E090809829B1C8262B7619/emoticons/1f61e.png" alt=":disappointed_face:" title=":disappointed_face:" /&gt;&lt;/P&gt;&lt;P&gt;I know this feature is experimental, but I'm not able squeeze any kind of performance information out of this API and get the following error no matter what parameters I provide:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;{
    "messages": [
        {
            "args": [],
            "default_message": "Invalid data points filter: found empty set of Counters for provided set of (cid,metric,types,resources)",
            "localized": "Invalid data points filter: found empty set of Counters for provided set of (cid,metric,types,resources)",
            "id": "com.vmware.vstats.data_points_invalid_counter_filter"
        }
    ]
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm guessing it's user error due to not understanding this API call.&amp;nbsp;&lt;/P&gt;&lt;P&gt;If anyone could provide an example of how to invoke this API, it would be greatly appreciated.&lt;/P&gt;&lt;P&gt;Thank you much!&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;R.&lt;/P&gt;</description>
    <pubDate>Fri, 30 Jun 2023 21:39:07 GMT</pubDate>
    <dc:creator>GreenMotion</dc:creator>
    <dc:date>2023-06-30T21:39:07Z</dc:date>
    <item>
      <title>Unable to retrieve performance metric for a vm</title>
      <link>https://communities.vmware.com/t5/VMware-code-Discussions/Unable-to-retrieve-performance-metric-for-a-vm/m-p/2971254#M2278</link>
      <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'd like to retrieve advanced performance metrics via a vmware API, but I can't figure out how (even after trying documentation and googling).&lt;/P&gt;&lt;P&gt;I want to get power usage data for single VMs in an ESXI Cluster. I am able to see a chart based based on this data in vSphere representing the power usage by clicking on VM &amp;gt; Monitor &amp;gt; Performance &amp;gt; Advanced.&lt;BR /&gt;&lt;BR /&gt;I am using the System Version&amp;nbsp;&lt;SPAN&gt;7.0.3.01300&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I tried the routes&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;/rest/vcenter/vm/my-vm-id&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;which unfortunately does not contain the power usage metrics&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;and&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;/api/stats/data/dp?metric=power.capacity.usage&amp;amp;types=VM=my-vm-id&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;trying to specify the vm id and vm type in varous combinations always receiving the error message:&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Invalid&amp;nbsp;data&amp;nbsp;points&amp;nbsp;filter&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Any thoughts/advice on this?&lt;BR /&gt;&lt;BR /&gt;(Please excuse me if the location of the post is wrong - this is my first post in the vmware communities)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jun 2023 06:49:37 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/VMware-code-Discussions/Unable-to-retrieve-performance-metric-for-a-vm/m-p/2971254#M2278</guid>
      <dc:creator>ilijaaf</dc:creator>
      <dc:date>2023-06-02T06:49:37Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to retrieve performance metric for a vm</title>
      <link>https://communities.vmware.com/t5/VMware-code-Discussions/Unable-to-retrieve-performance-metric-for-a-vm/m-p/2975369#M2284</link>
      <description>&lt;P&gt;Same here! &lt;img class="lia-deferred-image lia-image-emoji" src="https://communities.vmware.com/html/@8D3AC78033E090809829B1C8262B7619/emoticons/1f61e.png" alt=":disappointed_face:" title=":disappointed_face:" /&gt;&lt;/P&gt;&lt;P&gt;I know this feature is experimental, but I'm not able squeeze any kind of performance information out of this API and get the following error no matter what parameters I provide:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;{
    "messages": [
        {
            "args": [],
            "default_message": "Invalid data points filter: found empty set of Counters for provided set of (cid,metric,types,resources)",
            "localized": "Invalid data points filter: found empty set of Counters for provided set of (cid,metric,types,resources)",
            "id": "com.vmware.vstats.data_points_invalid_counter_filter"
        }
    ]
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm guessing it's user error due to not understanding this API call.&amp;nbsp;&lt;/P&gt;&lt;P&gt;If anyone could provide an example of how to invoke this API, it would be greatly appreciated.&lt;/P&gt;&lt;P&gt;Thank you much!&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;R.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jun 2023 21:39:07 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/VMware-code-Discussions/Unable-to-retrieve-performance-metric-for-a-vm/m-p/2975369#M2284</guid>
      <dc:creator>GreenMotion</dc:creator>
      <dc:date>2023-06-30T21:39:07Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to retrieve performance metric for a vm</title>
      <link>https://communities.vmware.com/t5/VMware-code-Discussions/Unable-to-retrieve-performance-metric-for-a-vm/m-p/2975763#M2285</link>
      <description>&lt;P&gt;Looks like&amp;nbsp;&lt;SPAN&gt;Create Acq Spec is not created.&lt;BR /&gt;vStats collects data only for the configured AcqSpecs.&lt;BR /&gt;&lt;BR /&gt;Try these steps:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1.&amp;nbsp;Create AcqSpecs with POST Create AcqSpec API&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;POST&lt;/STRONG&gt;: &lt;EM&gt;&lt;A href="https://{api_host}/api/stats/acq-specs" target="_blank" rel="noopener"&gt;https://{api_host}/api/stats/acq-specs&lt;/A&gt;&lt;/EM&gt;&lt;BR /&gt;Spec:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;{
    "counters": {
        "cid_mid": {
            "cid":"power.capacity.usage.VM"
        }
    },
    "interval" :"30",
    "expiration":"10000000000",
    "resources": [       
         {
            "type":"VM",
            "id_value":"&amp;lt;vm-moid&amp;gt;",
            "predicate":"EQUAL"
        }
    ]
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2.&amp;nbsp;Query Data Points Data:&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;GET&lt;/STRONG&gt;:&amp;nbsp;&lt;EM&gt;&lt;A title="https://{api_host}/api/stats/data/dp?cid=power.capacity.usage.VM&amp;amp;types=VM" href="https://{api_host}/api/stats/data/dp?cid=power.capacity.usage.VM&amp;amp;types=VM" target="_self"&gt;https://{api_host}/api/stats/data/dp?cid=power.capacity.usage.VM&amp;amp;types=VM&lt;/A&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 16:34:16 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/VMware-code-Discussions/Unable-to-retrieve-performance-metric-for-a-vm/m-p/2975763#M2285</guid>
      <dc:creator>doskiran</dc:creator>
      <dc:date>2023-07-04T16:34:16Z</dc:date>
    </item>
  </channel>
</rss>

