xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Yu Zhiguo <yuzg@cn.fujitsu.com>
To: Ian Jackson <Ian.Jackson@eu.citrix.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: Re: [PATCH] xl: Update memory info in xenstore when use 'xl	mem-set'
Date: Sun, 09 May 2010 16:45:20 +0800	[thread overview]
Message-ID: <4BE67620.7010803@cn.fujitsu.com> (raw)
In-Reply-To: <19428.20752.717993.453216@mariner.uk.xensource.com>

Hi Ian,

Ian Jackson wrote:
> 
> However, looking at this, it's far from clear why
> libxl_set_memory_target calls xc_domain_setmaxmem at all.  Can anyone
> explain ?

I'm trying to add subcommand 'mem-max', I think xc_domain_setmaxmem should
be used in it but not here.

I'll move this code to 'mem-max', and in 'mem-set', a check should be added
because setting memory larger than max memory is invalid.

1. Add 'mem-max'
  Add libxl_domain_setmaxmem, it calls xc_domain_setmaxmem.
  /local/domain/$domid/memory/static-max should be updated when set max memory,
it is missing now.

2. fix 'mem-set'
  Delete xc_domain_setmaxmem.
  Get max memory from /local/domain/$domid/memory/static-max, and then do value check.
It seems that we cannot get max memory use libxc routines.

Do you agree with me?



Add, I found another problem about mem-set.

I used 'xl mem-set' set the memory, but the size displayed in output of 'xm list'
did not change.
It seems that 'xm' get the memory size from xend, xend maintains some info of VM.
I'm not sure how to resolve this problem? Get info from xenstore?
What's your opinion?

# xl mem-set 3 204800
setting domid 3 memory to : 204800
# xl list
Name                                        ID   Mem VCPUs      State   Time(s)
...
pvguest1                                     3   200     2        r--      0.2
# xm list
Name                                        ID   Mem VCPUs      State   Time(s)
...
pvguest1                                     3   256     2     -b----      0.2



Regards
Yu Zhiguo

  reply	other threads:[~2010-05-09  8:45 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-07  9:39 [PATCH] xl: Update memory info in xenstore when use 'xl mem-set' Yu Zhiguo
2010-05-07 17:42 ` Ian Jackson
2010-05-09  8:45   ` Yu Zhiguo [this message]
2010-05-12  6:26     ` [PATCH 0/2] xl: Add subcommand mem-max and fix mem-set Yu Zhiguo
2010-05-12  6:41       ` Yu Zhiguo
2010-05-12 11:33         ` Stefano Stabellini
2010-05-12 11:39           ` Stefano Stabellini
2010-05-14  2:15         ` [PATCH] xl: Fix missing memory target in xenstore Yu Zhiguo
2010-05-12 15:33       ` [PATCH 0/2] xl: Add subcommand mem-max and fix mem-set Jonathan Knowles
2010-05-13 12:21         ` Stefano Stabellini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4BE67620.7010803@cn.fujitsu.com \
    --to=yuzg@cn.fujitsu.com \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).