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/
Home Products Support Community News


Re: [Xen-users] DomU slower with smp?

To: "Janusz Ulanowski" <janul666@xxxxxxxxx>
Subject: Re: [Xen-users] DomU slower with smp?
From: Luke S Crawford <lsc@xxxxxxxxx>
Date: 15 May 2008 20:38:55 -0400
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Thu, 15 May 2008 17:39:53 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <4cdb57b90805140435g58427e58w56848049ee027f9a@xxxxxxxxxxxxxx>
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: <4cdb57b90805140435g58427e58w56848049ee027f9a@xxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4
"Janusz Ulanowski" <janul666@xxxxxxxxx> writes:

> I just made simple peformance test with iozone tool on xen 3.2.1.
> It seems DomU  is much slower if using more than one cpu.

I would guess that maybe when you are running a single cpu on the DomU,
you are using different pcpu for dom0 and domu.  when you are using dual
cpu on the DomU, they likely step on oneanother.  

It's easy enough to move such things around with xm vcpu-pin and xm

If you only have 2 CPUs, (or if your DomU and Dom0 are using the same physical
cpu, check with xm vcpu-list)  you can have trouble because every I/O operation
in a DomU requires an I/O operation in the Dom0

A  simple thing that often helps I/O performance is to give the Dom0 
either a dedicated CPU (that no other Domain uses)  or failing that,
to give the Dom0 a large 'weight'  -  try 

xm sched-credit -d 0 -w 4096

or something (-w can be anything larger than what you set the DomUs to.  
Personally, I set it on the dom0 to equal the total megabytes of ram in 
the box, and each DomU to the megabytes of ram it is allocated, so each 
DomU has proportional fair share, and the Dom0 has greatest share of all
so that I/O goes through unmolested.)  

my experience has been that even if you don't mess with pining vcpus, 
performance is ok so long as the weight of Dom0 is sufficiently high.  

Xen-users mailing list

<Prev in Thread] Current Thread [Next in Thread>