<p>I'm using the latest prometheus 2.21.0 and latest node-exporter</p>
<p>Trying to run the query and getting <strong>no datapoints found</strong> however both metrics <code>kube_pod_container_resource_limits_memory_bytes</code> and <code>node_memory_MemTotal_bytes</code> are working independently and return data</p>
<pre><code>(sum(kube_pod_container_resource_limits_memory_bytes) / :node_memory_MemTotal_bytes:sum)*100
</code></pre>
<p>So two questions</p>
<ol>
<li>I never saw such syntax before <code>:node_memory_MemTotal_bytes:sum</code> - is it valid prometheus query?</li>
<li>What is wrong with the query if the syntax is correct?</li>
</ol>

<ol>
<li>This is a convention widely used in prometheus land. It means this metric is not one directly scraped from some target(s), but instead a result of recording rule. This convention is described <a href="https://prometheus.io/docs/practices/rules/#naming-and-aggregation" rel="nofollow noreferrer">here</a>.</li>
<li>If queries on both left and right side return data individually but after performing artihmetic on them you are left with no data then it probably means labels on them are not exactly the same. Execute them separately and compare labels you have on your results. Assuming that <code>:node_memory_MemTotal_bytes:sum</code> does return data then you'll probably have to add <code>sum</code> there too to remove any remaining labels there</li>
</ol>
