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

Re: [Xen-devel] [PATCH] Bug #327 xentop/libxenstat vcpu fix

On 16 Oct 2005, at 01:11, Daniel Stekloff wrote:

Ok.. so xm top/xentop is no longer broken - provided you don't care about out
of order vcpus.

This doesn't make sense..... see below.

xm vcpu-list is broken.

Yes, Ewan is working on a fix for this.

xm vcpu-enable will only enable vcpus in order. I can't, for instance, enable
vcpu 3 if vcpu 2 isn't enabled. xm vcpu-enable silently fails.

This is currently supposed to work. It looks as though the 'xm vcpu-enable/disable' commands are still not 100% robust. :-( Longer term, allowing an admin to take down specific vcpus probably isn't all that useful, so we may simplify the xm interface.

Do we no longer have or care about dicontiguous online maps? Or, do the tools
just need to catch up with your changes?

Although we don't care about exposing them via vcpu-enable/disable, I think we ought to handle them. A user logged into domU can still take down non-contiguous VCPUs, even if that functionality isn't exported via the xm interface.

I'm curious because xentop just takes the number of vcpus from domaininfo and calls GETVCPUCONTEXT starting with 0 and going until num-1. I just tried this on a 4 vcpu dom. I disabled vcpus 1 and 2, leaving 0 and 3 active. xentop worked fine but reported those vcpus as 0 and 1. GETVCPUCONTEXT returned the
as 0 and 1. Is this the way you want it to work?

That is definitely not how GETVCPUCONTEXT works. It won't renumber vcpus under your feet -- if you ask for vcpu3 then it is vcpu3's information that you will get.

One thing to bear in mind: GETVCPUCONTEXT will return info even about vcpus that are not currently online. To check for online status you need to use GETVCPUINFO and check the online field that is returned.

Perhaps you iterated from 0 to info.n_vcpu-1? The count from GETDOMAININFO only counts online vcpus, but doesn;t tell you which vcpus are online. We could also add a count 'max_vcpu' or easier: just iterate 0 to MAX_VIRT_CPU-1.

 -- Keir

Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.