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] [PATCH 00 of 24] xenpaging fixes for xen-unstable

To: Ian Campbell <Ian.Campbell@xxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH 00 of 24] xenpaging fixes for xen-unstable
From: Olaf Hering <olaf@xxxxxxxxx>
Date: Tue, 4 Oct 2011 17:05:45 +0200
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Tue, 04 Oct 2011 08:24:56 -0700
Dkim-signature: v=1; a=rsa-sha1; c=relaxed/relaxed; t=1317740752; l=2970; s=domk; d=aepfle.de; h=In-Reply-To:Content-Type:MIME-Version:References:Subject:Cc:To:From: Date:X-RZG-CLASS-ID:X-RZG-AUTH; bh=SEC/ZDJ6p3/iGEOH/cK/qSVpWcU=; b=qBxkhUNpfVk41KD4KYXAlYaH1kWBWkRlUN53BdJZScnK8z2y+4WeH+PDfSA1qjyMX/w 7uDgpu+ycCtOuoRVnBBy2sTuEFXlWzh5/hNbf5iBkfShU+yRzvG7NYic/8reCyUAQMKR8 vdizG3UyvgIeYJXyHz4uHjJWjrkAZHv/hwo=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1317721869.21903.110.camel@xxxxxxxxxxxxxxxxxxxxxx>
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: <patchbomb.1317657277@xxxxxxxxxxxx> <1317721869.21903.110.camel@xxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.21.rev5535 (2011-07-01)
On Tue, Oct 04, Ian Campbell wrote:

> totmem is unfortunately not all that descriptive to an end user of what
> it does (which I think is a general problem we have with the memory
> related options).
> 
> Currently the xl config file options are:
>         memory = actual start of day RAM
>         maxmem = max ram guest could balloon to (?)
> 
> How does POD fit in? Is it just maxmem-memory for HVM domains? (not
> really relevant for this discussion, more for completeness).
> 
> The associated command line options are:
>         mem-set (runtime equivalent of memory?)
>         mem-max (runtime equivalent of maxmem?)
> 
> Hmm, I was hoping that enumerating the existing options would make the
> name and semantics of the paging option magically pop into my head, I
> was wrong :-(
> 
> BTW tools/libxl/libxl_memory.txt should be patched by this series too,
> once we figure out what to call things.
> 
> The phrase "actual memory" is used in that document -- perhaps that is
> suitable terminology for totmem?

The naming of the various numbers is confusing, so far I could not come
up with a better name than tot_pages.

"actual target" is close to what xenpaging leaves for the guest, the
amount of video ram has to be substracted.

I think the code in libxl, xenstore and in my changes is not 100%
consistent with the figure below. I have to wade through the individual
members again and check if the math is correct in all places.

Olaf

/* === Domain memory breakdown: HVM guests ==================================
                           
             +  +----------+                                                 +  
          
             |  | shadow   |                                                 |  
          
             |  +----------+                                                 |  
          
    overhead |  | extra    |                                                 |  
          
             |  | external |                                                 |  
          
             |  +----------+                                      +          |  
          
             |  | extra    |                                      |          |  
          
             |  | internal |                                      |          |  
          
             +  +----------+                            +         |          | 
footprint  
             |  | video    |                            |         |          |  
          
             |  +----------+  +           +    +        |         | xen      |  
          
             |  |          |  | guest OS  |    |        | actual  | maximum  |  
          
             |  | guest    |  | real RAM  |    |        | target  |          |  
          
             |  |          |  |           |    | build  |         |          |  
          
             |  +----------+  +           |    | start  +         |          |  
          
      static |  | paging   |              |    |                  |          |  
          
     maximum |  +----------+              |    +                  +          +  
          
             |  |          |              |                                     
          
             |  |          |              |                                     
          
             |  | balloon  |              | build                               
          
             |  |          |              | maximum                             
          
             |  |          |              |                                     
          
             +  +----------+              +                                     
          
                
                
    extra internal = LIBXL_MAXMEM_CONSTANT
    extra external = LIBXL_HVM_EXTRA_MEMORY
    shadow = libxl_domain_build_info.shadow_memkb
    static maximum = libxl_domain_build_info.max_memkb
    video = libxl_domain_build_info.video_memkb
    build start = libxl_domain_build_info.target_memkb
    libxl_domain_setmaxmem -> xen maximum
    libxl_set_memory_target -> actual target
                
    build maximum = RAM as seen inside the virtual machine
                    Increase/Decrease via memory hotplug of virtual hardware (?)
                    xl mem-max (?)
    build start   = RAM usable by the guest OS
                    guest OS sees balloon driver as memory hog (?)
                    Increase/Decrease via commands to the balloon driver
                    xl mem-set
    real RAM      = RAM allocated for the guest
                    Increase/Decrease via commands to paging daemon
                    xl mem-FOO

    guest = real RAM
    paging = virtual RAM / swap
    balloon = will become real or virtual RAM after mem-set command


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