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-users

Re: [Xen-users] Disable SMP and assign each OS to direct access CPU

To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-users] Disable SMP and assign each OS to direct access CPU
From: Mark Williamson <mark.williamson@xxxxxxxxxxxx>
Date: Sun, 2 Dec 2007 04:15:06 +0000
Cc: Stephen Neoh <neohtm@xxxxxxxxx>, Sadique Puthen <sputhenp@xxxxxxxxxx>
Delivery-date: Sat, 01 Dec 2007 20:15:58 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <474D452B.2030102@xxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <cfb90afa0711280146y7d88d7c1g350e109318f59596@xxxxxxxxxxxxxx> <cfb90afa0711280210p29d2e4baxb3dbda919386b56b@xxxxxxxxxxxxxx> <474D452B.2030102@xxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.9.6 (enterprise 0.20070907.709405)
> IMHO, If the OS/hypervisor can detect the cpu cores, you should
> definitely be able to assign.
>
> Stephen Neoh wrote:
> > In that case, as i know, each physical core has it's own id. Can i
> > assign a specific core id to a domU/domO?

Actually you can assign individual logical processors (i.e. hyperthreads, if 
you have them) to domains.  By assigning all the logical processors on a 
core, you can assign a core to the domain; by assigning all the logical 
processors in a package you can assign all the cores in that package, and so 
on.

Of course, the domain isn't actually getting direct access to the processors - 
it still gets scheduled by Xen.  But if you arrange in the domain config 
files (and in xend-config.sxp for dom0) that each is assigned to run only on 
one specific logical CPU then it's basically equivalent to a domain running 
on each logical CPU all the time - because Xen won't have anything else to 
schedule!

It can be a performance win to assign a dedicated hyperthread (or potentially 
a core, but this would depend on your workload) to dom0.  I've had the 
impression that dom0 doesn't really need to be SMP anyhow to ensure decent 
performance to the domUs.  Assigning at least a hyperthread to dom0 can 
improve IO performance, although if you assign a core to dom0 obviously other 
domains can't use it for processing anymore.

For other domains, you may still find it's more flexible to let Xen schedule 
them across the available processors.  You can still cap the amount of CPU a 
domain uses.  But yes, you can pin domains to CPUs to get the effect of each 
core running a different domain.

Hope this helps,

Cheers,
Mark

> > On Nov 28, 2007 6:03 PM, Sadique Puthen < sputhenp@xxxxxxxxxx
> > <mailto:sputhenp@xxxxxxxxxx>> wrote:
> >
> >     Stephen Neoh wrote:
> >     > I'm quite new to XEN here. I got a question to ask about the XEN
> >     > configuration. Is it possible to disable the SMP function on the
> >
> >     dom0
> >
> >     > and assign each single domU to have direct access on the multicore
> >     > processor like Intel Quadcore?
> >
> >     Yes, Edit /etc/xend/xend-config.sxp and use (dom0-cpus x) to assign a
> >     single cpu to dom0.
> >
> >     For domus, define vcpus = x and cpus = x in guest configuration
> >     file to
> >     assign a single core or cpu to a guest. See /etc/xen/xmexample1
> >     for more
> >     details.
> >
> >     --Sadique
> >
> >    
> > ------------------------------------------------------------------------
> >
> >     > _______________________________________________
> >     > Xen-users mailing list
> >     > Xen-users@xxxxxxxxxxxxxxxxxxx
> >     > <mailto:Xen-users@xxxxxxxxxxxxxxxxxxx>
> >     > http://lists.xensource.com/xen-users
> >
> >     <http://lists.xensource.com/xen-users>



-- 
Dave: Just a question. What use is a unicyle with no seat?  And no pedals!
Mark: To answer a question with a question: What use is a skateboard?
Dave: Skateboards have wheels.
Mark: My wheel has a wheel!

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

<Prev in Thread] Current Thread [Next in Thread>
  • Re: [Xen-users] Disable SMP and assign each OS to direct access CPU, Mark Williamson <=