From: Avi Kivity <avi@redhat.com>
To: "Ozan Çağlayan" <ozan@pardus.org.tr>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
KVM list <kvm@vger.kernel.org>
Subject: Re: Poor KVM guest performance on an HP rack server
Date: Sun, 13 Dec 2009 12:13:38 +0200 [thread overview]
Message-ID: <4B24BE52.6060703@redhat.com> (raw)
In-Reply-To: <4B243B2B.806@pardus.org.tr>
On 12/13/2009 02:54 AM, Ozan Çağlayan wrote:
> Hi,
>
> We have an HP Proliant DL580G5 rack server. It has 4 Intel Xeon X7460(6
> core, 2.67GHz, 16MB L3) processor with 32GB of memory. /proc/cpuinfo has
> 24 x the following entry:
>
> I'm running 2.6.30.9-pae on top of it. We were actually planning to use
> it for a virtualization server for giving people dedicated *guest*
> access for their personal compile-farm needs.
>
First, as Jeremy notes, large memory machines want an x86_64 kernel.
But that doesn't explain the slowness.
> For testing purposes, we created a guest VM (2.6.30.9 too) on top of it
> with 2GB of virtual memory stored in a raw partition:
>
> qemu-kvm -cpu host -smp 2 -m 2047 -drive
> file=/dev/cciss/c1d0p1,if=virtio,cache=none,boot=on -net
> nic,model=virtio,macaddr=DE:AD:BE:EF:10:28 -net
> tap,ifname=tap0,script=/usr/bin/qemu-ifup -k tr -nographic -daemonize
>
>
> The problem is that I'm seeing very poor performance within the guest.
> I've googled a bit and seen similar bug reports/discussions ending with
> some tweaks (setting rotational to 1 for virtio_blk, using cache=none,
> etc.) and an explanation from Avi Kivity about the bad scalability of
> KVM on pre-Nehalem boxes under high build load.
>
-smp 2 should work perfectly well.
> But I fear that I'm far behind that *bad scalability*. I've made some
> comparisons with my QuadCore Q8300 (2MB cache) box. I won't give the
> whole numbers but for example,
>
> Running the autotools configure script of CUPS on that KVM guest (I can
> easily follow the output of configure line per line, it really really
> waits on some checks):
>
> real 0m52.876s
> user 0m4.892s
> sys 0m55.705s
>
> On the host (while running the guest vm):
>
> real 0m8.193s
> user 0m3.099s
> sys 0m4.055s
>
> On the quadcore box:
>
> real 0m8.424s
> user 0m2.651s
> sys 0m2.879s
>
> Both with cold cache (echo 3> /proc/sys/vm/drop_caches)
>
> So it's not even a high build load. I've tried with -smp 8 (which showed
> worse numbers than -smp 2 and 4), with IDE instead of virtio, without
> -cpu host parameter but can't get near 30 (I've got 35 seconds with
> tuning read_ahead_kb, on top of IDE instead of virtio, etc.) seconds at all.
>
> I've also tried hugetlbfs for backing the memory within the guest.
>
> I'm using the latest kvm-mod-2.6.32 built on top of 2.6.30.9.
>
> So is this huge performance difference should be accepted as normal or
> am I missing some big things?
>
First, are you sure that kvm is enabled? 'info kvm' in the monitor.
Second, is the workload cpu bound or I/O bound? Both from the guest's
and host's point of view.
--
error compiling committee.c: too many arguments to function
next prev parent reply other threads:[~2009-12-13 10:13 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-13 0:54 Poor KVM guest performance on an HP rack server Ozan Çağlayan
2009-12-13 6:10 ` Jeremy Fitzhardinge
2009-12-13 10:12 ` Ozan Çağlayan
2009-12-13 18:29 ` Jeremy Fitzhardinge
2010-03-12 17:18 ` Ozan Çağlayan
2010-03-13 8:21 ` Avi Kivity
2009-12-13 10:13 ` Avi Kivity [this message]
2009-12-13 11:36 ` Ozan Çağlayan
2009-12-13 11:58 ` Ozan Çağlayan
2009-12-15 10:29 ` Avi Kivity
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=4B24BE52.6060703@redhat.com \
--to=avi@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=ozan@pardus.org.tr \
/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