From mboxrd@z Thu Jan 1 00:00:00 1970 From: Konrad Rzeszutek Wilk Subject: Re: domain creation vs querying free memory (xend and xl) Date: Thu, 27 Sep 2012 07:26:24 -0400 Message-ID: <20120927112624.GA8576@phenom.dumpdata.com> References: <53b8c758-2675-42a7-b63f-4f9ad0006d84@default> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <53b8c758-2675-42a7-b63f-4f9ad0006d84@default> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Dan Magenheimer , mike.mcclurg@citrix.com, anil@recoil.org Cc: Kurt Hackel , xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org On Wed, Sep 26, 2012 at 02:17:06PM -0700, Dan Magenheimer wrote: > I was asked a question that seems like it should be obvious > but it doesn't seem to be, at least in xm-land. I'll look > into it further, as well as for xl, but I thought I'd ask > first to see if there is a known answer or if this is a known > problem: > > Suppose that xm/xl create is issued on a large-memory > domain (PV or HVM or, future, PVH). It takes awhile > for this domain to launch and during at least part of this > time, the toolset hasn't yet requested all of the > required memory from the hypervisor to complete the > launch of the domain... or perhaps the toolset has, > but the hypervisor is slow about calling the long sequence > of page allocations (e.g. maybe because it is zeroing > each page?). > > Then it is desired to launch a second large-memory domain. > The tools can query Xen to see if there is sufficient RAM > and there is, because the first launch has not yet > allocated all the RAM assigned to it. > > But the second domain launch fails, possibly after > several minutes because, actually, there isn't enough > physical RAM for both. > > Does this make sense? Should the tools "reserve" > maxmem as a "transaction" and/or ensure that "xm/xl > free" calls account for the entire requested amount > of RAM? Or maybe xl _does_ work this way? So say "freeze" the amount of free memory. Lets CC the XCP folks > > Thanks for any comments or discussion! > > Dan