WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] How to determine memory size in HVM

To: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] How to determine memory size in HVM
From: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>
Date: Wed, 10 Jun 2009 11:47:26 +0100
Cc: Steven Smith <Steven.Smith@xxxxxxxxxxxxx>, James Harper <james.harper@xxxxxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Wed, 10 Jun 2009 03:47:52 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:in-reply-to :references:date:x-google-sender-auth:message-id:subject:from:to:cc :content-type:content-transfer-encoding; bh=LqvlFiaxGBH5M+iChdsvothWGjeRrEG4WKqNZoNch4A=; b=Cnr2FPGYH8pHPFcx/1aXGsqhMUI1kfNWv5sU8pCwqXtn6SolqyxuJEPwUosOmSKCu+ Un2EdKRsD4eA/AI0FEUX7s2l/jLRYIWkyAwB6hal+6Tub2ueunb0mAfRHFprQTk+2V5U kOea6VuZaKC0NTK2K5yzo0mBEa1mXCB5dO71A=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=MFqqWyJWKRuWjKTFVDHwAe7L+0BpKcJadRntLp4Lb+N/c1Clif9S71ZlA0WRTDA4lB mG87P56G6M1ouLTW8AupJKJOLdEH/RuoJ9EQhM4XvWaAyMLKPXMOxsuAk6VBEntr2gJ+ 4mMuvbhaqshiQeaaH9JIaA5ug2u9R2BTxonJQ=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C653B3FA.D0B7%keir.fraser@xxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <AEC6C66638C05B468B556EA548C1A77D016DD675@trantor> <C653B3FA.D0B7%keir.fraser@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Tue, Jun 9, 2009 at 6:38 AM, Keir Fraser<keir.fraser@xxxxxxxxxxxxx> wrote:
>
> The new HVM populate-on-demand memory support should be able to help. I
> suppose also some tools changes may be necessary in conjunction with this.
> Or domain config changes. George Dunlap and Steven Smith can probably
> advise.

I know all about the populate-on-demand stuff, but not very much about
the tools, and unfortunately that's where the change is needed, I
think. :-)

So the basic thing we need is to have not a single memory variable,
but two variables: "maximum" and "target".  Maximum is what is
reported to a VM at boot, and target is how much we want it to
actually have.

What populate-on-demand allows you to do is to tell a fully
virtualized VM it has maximum memory (say, 1G), but only give it
target memory (say, 256M).  When the VM boots, the OS will check its
e820 mapping, see 1G reported there, and set things up appropriately.
Then, when the balloon driver comes up, it will inflate the balloon to
maxmem-target.

The problem with rebooting sounds like it's due to the tools not being
designed with this distinction in mind.  So "xm mem-set" should change
target, but not maxmem; and ideally, when the VM reboots, it should be
created with the (maxmem,target) populate-on-demand split again.

 -George

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel