Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cpu usage not working like explained in the readme. #292

Open
hugosxm opened this issue Oct 22, 2024 · 1 comment
Open

Cpu usage not working like explained in the readme. #292

hugosxm opened this issue Oct 22, 2024 · 1 comment

Comments

@hugosxm
Copy link

hugosxm commented Oct 22, 2024

Hi,

I have a 48CPU node, and it shows that in the exporter metrics :
pve_cpu_usage_limit{id="node/vc1"} 48.0

But if I stress the cpu with the stress commande, I have 25% in the proxmox webui and :

pve_cpu_usage_ratio{id="node/vc1"} 0.255540285174369

But the doc says :

# HELP pve_cpu_usage_ratio CPU usage (value between 0.0 and pve_cpu_usage_limit)

I am on pve 8.1.10.

So I think the truth is that the metric is just a "classic" percentage going from 0 to 1 and not from 0 to pve_cpu_usage_limit. If someone can confirm that ?

Thanks

@znerol
Copy link
Member

znerol commented Oct 22, 2024

Yes, I guess that the docs are wrong. A more accurate explanation is given on the API docs page.

  • cpu: CPU utilization (when type in node,qemu,lxc).
  • maxcpu: Number of available CPUs (when type in node,qemu,lxc).

We should probably just use the upstream descriptions. PR welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants