[libvirt] [PATCHv6 02/11] qemu: bulk stats: implement CPU stats group

Eric Blake eblake at redhat.com
Tue Sep 16 21:24:23 UTC 2014


On 09/15/2014 09:42 AM, Peter Krempa wrote:
> From: Francesco Romani <fromani at redhat.com>
> 
> This patch implements the VIR_DOMAIN_STATS_CPU_TOTAL group of
> statistics.
> 
> Signed-off-by: Francesco Romani <fromani at redhat.com>
> Signed-off-by: Peter Krempa <pkrempa at redhat.com>
> ---
> 
> Notes:
>     Version 6:
>     - added a check that skips the stats group in case cgroups aren't available for the given domain
> 
>  include/libvirt/libvirt.h.in |  1 +
>  src/libvirt.c                |  7 +++++++
>  src/qemu/qemu_driver.c       | 44 ++++++++++++++++++++++++++++++++++++++++++++
>  3 files changed, 52 insertions(+)
> 

> +++ b/src/libvirt.c
> @@ -21596,6 +21596,13 @@ virConnectGetDomainCapabilities(virConnectPtr conn,
>   * "state.reason" - reason for entering given state, returned as int from
>   *                  virDomain*Reason enum corresponding to given state.
>   *
> + * VIR_DOMAIN_STATS_CPU_TOTAL: Return CPU statistics and usage information.
> + * The typed parameter keys are in this format:
> + * "cpu.time" - total cpu time spent for this domain as unsigned long long.
> + * "cpu.user" - user cpu time spent as unsigned long long.
> + * "cpu.system" - system cpu time spent as unsigned long long.

Missing the word "nanoseconds" on each of these three (at least, I'm
assuming that's the unit, based on VIR_DOMAIN_CPU_STATS_CPUTIME).

ACK with that fixed.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 539 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20140916/0dce4dc5/attachment-0001.sig>


More information about the libvir-list mailing list