canonical / cloudstats

GNU General Public License v3.0
1 stars 2 forks source link

Reporter crashes if hypervisor_vcpus_total is 0 #16

Open agileshaw opened 1 year ago

agileshaw commented 1 year ago

I've identified a divide-by-zero issue related to hypervisor_vcpus_total.

For a specific customer which only has physical CPUs (100% dedicated, no vCPUs whatsoever), these queries return the value "+Inf":

round(min(hypervisor_vcpus_used / hypervisor_vcpus_total), 0.1) round(max(hypervisor_vcpus_used / hypervisor_vcpus_total), 0.1)

We should consider:


Imported from Launchpad using lp2gh.