On Tue, Apr 29, 2014 at 08:54:26PM +0400, Roman Bogorodskiy wrote:
Ján Tomko wrote:
> On 04/24/2014 11:14 AM, Roman Bogorodskiy wrote:
> > Ján Tomko wrote:
> >
> >> On 04/22/2014 07:44 PM, Roman Bogorodskiy wrote:
> >>> For per CPU stats, implement virBhyveGetDomainPercpuStats() that
> >>> uses bhyvectl tool to obtain the guest's vcpu stats.
> >>>
> >>
> >> In virDomainGetCPUStats API, the start_cpu and ncpus parameters refer to
host
> >> CPUs, not the vcpus.
> >
> > Looks like I misunderstood the API. :-(
> >
> > In other words, this API operates with the host CPUs? So if user calls
> > it with e.g. start_cpu = 2 and ncpus = 2, I should return info on how
> > much time host CPUs 2 and 3 spend on the given domain (as the opposite
> > to how much time domain's vcpu 2 and vcpu 3 were busy)?
> >
>
> Yes.
>
> Jan
>
Looks like FreeBSD does not support such kind of per-cpu reporting for
host cpus. Just to make sure I didn't miss something, I asked that
question of the FreeBSD virtualization maillist and looks like I'm right
about that [1].
Would it better to abandon this feature for now and wait when it'd be
supported (I'm not sure if/when it's going to happen), or just leave the
code that reports only the stats for all cpus?
I think it is better to leave it unsupported, so apps can see the
VIR_ERR_NO_SUPPORT error and not mistakenly interpret incorrect data.
Regards,
Daniel
--
|:
http://berrange.com -o-
http://www.flickr.com/photos/dberrange/ :|
|:
http://libvirt.org -o-
http://virt-manager.org :|
|:
http://autobuild.org -o-
http://search.cpan.org/~danberr/ :|
|:
http://entangle-photo.org -o-
http://live.gnome.org/gtk-vnc :|