All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andre Przywara <andre.przywara@amd.com>
To: Dan Magenheimer <dan.magenheimer@oracle.com>
Cc: George Dunlap <George.Dunlap@eu.citrix.com>,
	xen-devel@lists.xensource.com,
	Keir Fraser <keir.fraser@eu.citrix.com>,
	Papagiannis Anastasios <apapag@ics.forth.gr>
Subject: Re: Xen 3.4.1 NUMA support
Date: Mon, 9 Nov 2009 16:02:42 +0100	[thread overview]
Message-ID: <4AF82F12.6040400@amd.com> (raw)
In-Reply-To: <bd4f4a54-5269-42d8-b16d-cbdfaeeba361@default>

Dan Magenheimer wrote:
>> Add Xen boot parameter 'numa=on' to enable NUMA detection. 
>> Then it's up to you to, for example, pin domains to specific nodes, 
>> using the 'cpus=...' option in the domain config file. See
>> /etc/xen/xmexample1 for an example of its usage.
> VMware has the notion of a "cell" where VMs can be
> scheduled only within a cell, not across cells.
> Cell boundaries are determined by VMware by
> default, though certains settings can override them.
Well, If I got this right, then you are describing the current behaviour 
of Xen. It has a similar feature for some time now (since 3.3, I guess). 
When you launch a domain on a numa=on machine, it will pick the least 
busiest node (which can hold the requested memory) and restrict the 
domain to that node (by only allowing CPUs of that node).
This is in XendDomainInfo.py (c/s 17131, 17247, 17709)
Looks like this one:
(kernel xen.gz numa=on dom0_mem=6144M dom0_max_vcpus=6 dom0_vcpus_pin)
# xm create opensuse.hvm
# xm create opensuse2.hvm
# xm vcpu-list
Name                                ID  VCPU   CPU State   Time(s) CPU 
Affinity
001-LTP                              1     0     6   -b-      17.8 6-11
001-LTP                              1     1     7   -b-       6.3 6-11
002-LTP                              2     0    12   -b-      19.0 12-17
002-LTP                              2     1    16   -b-       1.6 12-17
002-LTP                              2     2    17   -b-       1.7 12-17
002-LTP                              2     3    14   -b-       1.6 12-17
002-LTP                              2     4    16   -b-       1.6 12-17
002-LTP                              2     5    15   -b-       1.5 12-17
002-LTP                              2     6    12   -b-       1.3 12-17
002-LTP                              2     7    13   -b-       1.8 12-17
Domain-0                             0     0     0   -b-      12.6 0
Domain-0                             0     1     1   -b-       7.6 1
Domain-0                             0     2     2   -b-       8.0 2
Domain-0                             0     3     3   -b-      14.6 3
Domain-0                             0     4     4   r--       1.4 4
Domain-0                             0     5     5   -b-       0.9 5
# xm debug-keys U
(XEN) Domain 0 (total: 2097152):
(XEN)     Node 0: 2097152
(XEN)     Node 1: 0
(XEN)     Node 2: 0
(XEN)     Node 3: 0
(XEN)     Node 4: 0
(XEN)     Node 5: 0
(XEN)     Node 6: 0
(XEN)     Node 7: 0
(XEN) Domain 1 (total: 394219):
(XEN)     Node 0: 0
(XEN)     Node 1: 394219
(XEN)     Node 2: 0
(XEN)     Node 3: 0
(XEN)     Node 4: 0
(XEN)     Node 5: 0
(XEN)     Node 6: 0
(XEN)     Node 7: 0
(XEN) Domain 2 (total: 394219):
(XEN)     Node 0: 0
(XEN)     Node 1: 0
(XEN)     Node 2: 394219
(XEN)     Node 3: 0
(XEN)     Node 4: 0
(XEN)     Node 5: 0
(XEN)     Node 6: 0
(XEN)     Node 7: 0

Note that there were no cpus= lines in the config files, Xen did that 
automatically.

Domains can be localhost-migrated to another node:
# xm migrate --node=4 1 localhost
The only issue is with domains larger than a node.
If someone has a useful use-case, I can start rebasing my old patches 
for NUMA aware HVM domains to Xen unstable.

Regards,
Andre.

BTW: Shouldn't we set finally numa=on as the default value?

-- 
Andre Przywara
AMD-OSRC (Dresden)
Tel: x29712

  parent reply	other threads:[~2009-11-09 15:02 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-04 12:02 Xen 3.4.1 NUMA support Papagiannis Anastasios
2009-11-04 12:32 ` Keir Fraser
2009-11-06 18:07   ` Dan Magenheimer
2009-11-09 11:33     ` George Dunlap
2009-11-09 11:39       ` Dulloor
2009-11-09 12:29         ` George Dunlap
2009-11-09 12:51           ` Dulloor
2009-11-09 11:44       ` Juergen Gross
2009-11-09 12:07         ` George Dunlap
2009-11-09 12:40         ` Keir Fraser
2009-11-09 15:02     ` Andre Przywara [this message]
2009-11-09 15:06       ` George Dunlap
2009-11-09 22:51         ` Andre Przywara
2009-11-10  6:56           ` Dulloor
2009-11-10  7:49             ` Andre Przywara
2009-11-13 14:14         ` Andre Przywara
2009-11-13 14:29           ` Ian Pratt
2009-11-13 15:25             ` George Dunlap
2009-11-13 15:35               ` Ian Pratt
2009-11-13 15:27             ` Keir Fraser
2009-11-13 15:40               ` Ian Pratt
2009-11-13 16:02                 ` Keir Fraser
2009-11-13 14:31           ` Keir Fraser
2009-11-13 15:38             ` Ian Pratt
2009-11-09 15:19       ` Jan Beulich
2009-11-10  1:46         ` Ian Pratt
2009-11-10  8:51           ` Jan Beulich
2009-11-10  8:57             ` Keir Fraser
2009-11-12 16:09         ` Keir Fraser
2009-11-30 15:40         ` [PATCH] tools: avoid over-commitment if numa=on Andre Przywara

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=4AF82F12.6040400@amd.com \
    --to=andre.przywara@amd.com \
    --cc=George.Dunlap@eu.citrix.com \
    --cc=apapag@ics.forth.gr \
    --cc=dan.magenheimer@oracle.com \
    --cc=keir.fraser@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.