What's the precision of the domain cpu stats?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, everyone
        I'm using libvirt and resort to virDomainGetCPUStats for cpu
usage by one domain. In my system, Ubuntu-11.10 64bit with 2 cores and
Qemu Hyperviser, this function returns something like this:
        virTypedParameter[0]
       {
           field: "cpu_time"
           type: 4
           value.ul  51640610899
       }
       virTypedParameter[1]
       {
           field: "cpu_time"
           type: 4
           value.ul  55302820304
       }

      This 51640610899 and 55302820304  kind of conflict the result
returned by "cat /proc/stat | grep cpu"
cpu  449224 6812 89433 4407261 50327 1 2443 0 13041 0
cpu0 224251 2603 43144 2195672 34682 0 2350 0 6692 0
cpu1 224972 4209 46289 2211589 15644 0 93 0 6349 0

I know the precision of /proc/stat is 1/HZ,  so what's the precision
of CPU stats returned by virDomainGetCPUStats?

_______________________________________________
libvirt-users mailing list
libvirt-users@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvirt-users


[Index of Archives]     [Virt Tools]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]

  Powered by Linux