From mboxrd@z Thu Jan 1 00:00:00 1970 From: Zhigang Wang Subject: Re: xl list -l doesn't work for incoming domain Date: Mon, 10 Nov 2014 12:08:18 -0500 Message-ID: <5460F102.9000100@oracle.com> References: <545BC8A2.20604@oracle.com> <20141107104752.GB28188@zion.uk.xensource.com> <545CF499.8080606@oracle.com> <20141110123525.GD28360@zion.uk.xensource.com> <5460D342.9090308@oracle.com> <20141110152535.GA6110@zion.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta4.messagelabs.com ([85.158.143.247]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XnsS4-0006gZ-T2 for xen-devel@lists.xenproject.org; Mon, 10 Nov 2014 17:08:28 +0000 In-Reply-To: <20141110152535.GA6110@zion.uk.xensource.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: Wei Liu Cc: xen-devel List-Id: xen-devel@lists.xenproject.org On 11/10/2014 10:25 AM, Wei Liu wrote: > On Mon, Nov 10, 2014 at 10:01:22AM -0500, Zhigang Wang wrote: >> On 11/10/2014 07:35 AM, Wei Liu wrote: >>> I see. At that point the configuration was not available, yet. After the >>> domain is successfully migrated, the configuration should be available. >>> >>> I think a domain under construction without domain configuration is a >>> valid state. What do you think? >> >> Here is my thought: >> >> 1. In this design, if I watch xenstore @introduceDomain, it will not been >> triggered until migration finish. >> > > OK. What in this design makes behavior different than before? Are you > suggesting "xl list -l" has something to do with your xenstore watch? I > don't think I can get this. > > My guess is that, you have some tool that watches @introduceDomain, > which happens *before* the domain creation is finished. And your tool > needs to get domain information once your watch fires. Here with this > design, your tool cannot get the correct information until migration is > finished. Am I right? > > However, in previous design, even if you manage to get configuration > before migration is finished, I don't think that configuration reflects > the true configuration of that domain. It's conceptually bogus. > > In any case, if you look at xenstore code, XS_INTRODUCE doesn't mean a > domain is started, so using it for that purpose would be wrong. > >> 2. Because we have multiple places (hypervisor, xenstore, /var/lib/xen) holding >> domain state, we need to define what does it mean by "VM started". >> > > If my above analysis is correct, will some kind of @startDomain event solve > your problem? > > But this involves making changes to Xenstore protocol. Let's not go into > details until we make sure your requirement is well understood. We do currently watch xenstore @introduceDomain for VM start. I thought the @introduceDomain behavior is different than xm/xend, but I just did a test and I was wrong. xm/xend also trigger @introduceDomain until domain migration finish. (but before @introduceDomain, all the VM xenstore entries are already there.) Right now, I'm all set if we fix the xl list -l issue during migration. Thanks, Zhigang