From: Ian Campbell Subject: Re: domains being migrated state message improvements Date: Fri, 2 May 2014 15:15:13 +0100 Message-ID: <1399040113.6043.37.camel@kazak.uk.xensource.com> References: <1399036605.3861.14.camel@nereid> <53639C78.2050603@citrix.com> <1399037350.6043.9.camel@kazak.uk.xensource.com> <5363A03F.3050109@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <5363A03F.3050109@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Andrew Cooper Cc: sparvu@systemdatarecorder.org, xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org On Fri, 2014-05-02 at 14:40 +0100, Andrew Cooper wrote: > On 02/05/14 14:29, Ian Campbell wrote: > > > >> I would agree that it is a little confusing. '------' means runnable > >> but not running, in this case due to vcpu over subscription. > > Is that not "blocked"? > > Blocked is any vcpu/domain pause count. For healthy domains, this is > usually a yielded timeslice, which is why idle domains are almost always > '-b----'. > > > > > BTW, the "migration" referred to here is VCPU migration to another PCPU > > rather than domain migration. (It came up because that's another one of > > the VCPU pause flags alongside blocked et al) > > I do not think vcpu motion around the system is actually relevant to the > problem described. It was due to this code in getdomaininfo: /* * - domain is marked as blocked only if all its vcpus are blocked * - domain is marked as running if any of its vcpus is running */ for_each_vcpu ( d, v ) { vcpu_runstate_get(v, &runstate); cpu_time += runstate.time[RUNSTATE_running]; info->max_vcpu_id = v->vcpu_id; if ( !test_bit(_VPF_down, &v->pause_flags) ) { if ( !(v->pause_flags & VPF_blocked) ) flags &= ~XEN_DOMINF_blocked; if ( v->is_running ) flags |= XEN_DOMINF_running; info->nr_online_vcpus++; } } If a domain was not running or blocked then it could end up with neither set, I thought this might be when some other VPF was applied, like VPF_migrating (or VPF_mem_paging etc). Or are you saying that those always come along with a VPF_blocked? Ian.