All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Tokarev <mjt@tls.msk.ru>
To: Stefan Pietsch <stefan.pietsch@lsexperts.de>
Cc: Hans-Kristian Bakke <hkbakke@gmail.com>, kvm@vger.kernel.org
Subject: Re: Virtio network performance on Debian
Date: Mon, 16 Apr 2012 13:28:50 +0400	[thread overview]
Message-ID: <4F8BE652.1090007@msgid.tls.msk.ru> (raw)
In-Reply-To: <4F8BDFDC.4090507@sp.consulting.lsexperts.de>

On 16.04.2012 13:01, Stefan Pietsch wrote:
> On 12.04.2012 09:42, Hans-Kristian Bakke wrote:
>> Hi
>>
>> For some reason I am not able to get good network performance using
>> virtio/vhost-net on Debian KVM host (perhaps also valid for Ubuntu
>> hosts then).
>> Disc IO is very good and the guests feels snappy so it doesn't seem
>> like there is something really wrong, just something suboptimal with
>> the networking.
> 
> [......]
> 
>> I have tried:
>> ----------------
>> - Replacing Debian Wheezy with Debian Squeeze (stable, kernel
>> 2.6.32-xx) - even worse results
>> - Replacing kernel 3.2.0-2-amd64 with vanilla kernel 3.4-rc2 and
>> config based on Debians included config - no apparent change
>> - Extracted the kernel-config file from Fedora 17 alphas kernel and
>> used this to compile a new kernel based on Debian Wheezys kernel
>> source - slightly worse results
>> - ...in addition to exchanging Debian with Fedora 17 alpha, Proxmox
>> 1.9 and 2.0 and ESXi 5 which all have expected network performance
>> using virtio.
>>
>> So, I am at a loss here. I does not seem to be kernel config related
>> (as using Fedoras config on Debian kernel source didn't do anything
>> good) so I think it must be either a kernel patch that red hat kernel
>> based distros uses to make virtio/vhost much more efficient or perhaps
>> something with Debians qemu-version, bridging or something.

Hans-Kristian submitted a bugreport to Debian BTS about this,
http://bugs.debian.org/668594 .  In this case it turns out to
be a problem with particular qemu-kvm userspace binary build,
maybe the toolchain used, maybe something else - I don't yet
know.  This is not the first time this version is mentioned
as being slow (slower) with network transfers, here's another
bugreport which I merely ignored till now -- see
http://bugs.debian.org/665046 .

I'm working on this, or trying to anyway.

> I have made some tests with a Debian Squeeze KVM host running with the
> Linux Kernel 2.6.39 from backports and the Kernel version 2.6.32-11-pve
> from Proxmox.
> 
> (http://download.proxmox.com/debian/dists/squeeze/pve/binary-amd64/pve-kernel-2.6.32-11-pve_2.6.32-66_amd64.deb)

These are very different.  Note that 2.6.32 does not have vhost-net
support which is used by Hans-Kristian and speeds up network operations
dramatically.

> Network performance between two virtual machines on the same host is
> significantly slower with the Debian kernel:
> 
> 2.6.39-bpo.2-amd64 : 1.31 Gbits/sec
> 2.6.32-11-pve      : 2.20 Gbits/sec

Please try current debian kernel.  There were a few issues with that
2.6.32 backport, but I don't know the details and don't know if these
affects qemu/kvm in any way or not.  And again, if you really want
good networking speeds, you should use vhost-net which is is not
supported by 2.6.32 kernel.

> iperf tests between a virtual machine and the KVM host connected to the
> same local bridge interface showed similar results.
> 
> Are there other people who can confirm this?

Thanks,

/mjt

  reply	other threads:[~2012-04-16  9:28 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-12  7:42 Virtio network performance on Debian Hans-Kristian Bakke
2012-04-16  9:01 ` Stefan Pietsch
2012-04-16  9:28   ` Michael Tokarev [this message]
2012-04-16 11:29   ` Alexandre DERUMIER
2012-04-16 11:46     ` Hans-Kristian Bakke
2012-04-17  8:33 ` Michael Tokarev

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=4F8BE652.1090007@msgid.tls.msk.ru \
    --to=mjt@tls.msk.ru \
    --cc=hkbakke@gmail.com \
    --cc=kvm@vger.kernel.org \
    --cc=stefan.pietsch@lsexperts.de \
    /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.