All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ulrich Schreiner <ulrich.schreiner-sZDnKEZIvs8b1SvskN2V4Q@public.gmane.org>
To: Dor Laor <dor.laor-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
	Avi Kivity <avik-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
Subject: Re: kvm very slow
Date: Tue, 07 Aug 2007 11:43:26 +0200	[thread overview]
Message-ID: <1186479806.3370.22.camel@vaio> (raw)
In-Reply-To: <64F9B87B6B770947A9F8391472E032160D17A0EA-yEcIvxbTEBqsx+V+t5oei8rau4O3wl8o3fe8/T/H7NteoWH0uzbU5w@public.gmane.org>

today morning i compiled kvm-33 and the output of kvm-stat is much
better now (guest in idle):

kvm statistics

 efer_reload  10944273    6504
 exits        13722688    6967
 halt_exits    1084344     935
 invlpg              0       0
 io_exits      7668914    5070
 irq_exits       27886       2
 irq_window      11477       1
 light_exits   2778416     462
 mmio_exits    2153709     498
 pf_fixed      1085923       0
 pf_guest       459144       0
 request_irq         0       0
 signal_exit     25818       0
 tlb_flush      228295       5


i don't know if these numbers are ok; do you still need the generated
qemu.log for ioport access? if you need it i will upload it to my public
server.

but: the system is slow. it is extremely slow when booting and the
guest-system clock ist twice as slow as the host-system clock (both are
idle; ok, the host as a runnung qemu-instance :-).

when starting i get:

Could not configure '/dev/rtc' to have a 1024 Hz timer. This is not a
fatal
error, but for better emulation accuracy either use a 2.6 host Linux
kernel or
type 'echo 1024 > /proc/sys/dev/rtc/max-user-freq' as root.

well i HAVE a 2.6kernel (2.6.22.1-41.fc7), but i cannot set
dev.rtc.max-user-freq, i only can set the high precision event timer

dev.hpet.max-user-freq = 1024

which i have done. but the message always appears. i don't know if this
is ignorable.







Am Dienstag, den 07.08.2007, 00:44 -0700 schrieb Dor Laor:
> >no ideas what can be done? why it is so slow?
> 
> Let's try to catch the cause for the 74k ioexits per second.
> Please add #define DEBUG_IOPORT in qemu/vl.c and qemu/exec.c and
> recompile.
> After that when the guest runs and does 74k ioexits on idle, enter the
> qemu's monitor (ctrl-alt-1)
> enter 'log ioport'. All guest's ioport access will be written to
> /tmp/qemu.log.
> Be kind enough to calculate the statistics of ioport access per port
> number a second.
> With the numbers we can see the hardware that causes the slowness.
> -- Dor.
> 
> btw: are you using kvm-33 or older?
> 
> >
> >i've tried the "-L /usr/shar/kvm" to use the kvm-bios but no better
> >performance ...
> >
> >Am Donnerstag, den 02.08.2007, 11:24 +0300 schrieb Avi Kivity:
> >> Ulrich Schreiner wrote:
> >> > dmesg|grep kvm
> >> >
> >> > SELinux: initialized (dev kvmfs, type kvmfs), uses genfs_contexts
> >> > kvm: emulating exchange as write
> >> >
> >> >
> >>
> >> There may be messages that aren't prefixed with 'kvm:' (that's a bug
> >> btw).  Please check.
> >>
> >> > now booting into a F7 image, after the system is ready (and in
> >idle):
> >> >
> >> > top
> >> >    PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+
> >COMMAND
> >> > 14917 root      20   0  332m  71m  66m S    6  0.9   1:17.05 qemu-
> >kvm
> >> > 14954 root      20   0 14552 1072  812 R    0  0.0   0:00.01 top
> >> >      1 root      20   0 10320  680  572 S    0  0.0   0:02.02 init
> >> >
> >> > kvm_stat (snapshot):
> >> >
> >> > kvm statistics
> >> >
> >> >   exits        12254399   79079
> >> >   halt_exits     326543    4632
> >> >   invlpg              0       0
> >> >   io_exits      6539798   74320
> >> >   irq_exits       43523      29
> >> >   irq_window       4984       0
> >> >   mmio_exits    1319016       0
> >> >   pf_fixed      3140955      56
> >> >   pf_guest       448187       6
> >> >   request_irq         0       0
> >> >   signal_exit     39728       0
> >> >   tlb_flush       29511      31
> >> >
> >>
> >> Wow -- lots of I/O exits.  What does 'top' in the guest say? 'hdparm
> >> /dev/hda' in the guest?
> >>
> >> > when logging into the virtual machine (via ssh) the virtual world
> is
> >> > very slow: i set the time with "ntpdate" and wait exact one minute
> >in
> >> > reality. in the virtual image only 24sec are gone!
> >> >
> >> > and everything else in the image is really slow.
> >> >
> >> >
> >>
> >
> >
> >-----------------------------------------------------------------------
> -
> >-
> >This SF.net email is sponsored by: Splunk Inc.
> >Still grepping through log files to find problems?  Stop.
> >Now Search log events and configuration files using AJAX and a browser.
> >Download your FREE copy of Splunk now >>  http://get.splunk.com/
> >_______________________________________________
> >kvm-devel mailing list
> >kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> >https://lists.sourceforge.net/lists/listinfo/kvm-devel


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/

  parent reply	other threads:[~2007-08-07  9:43 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-01  5:22 kvm very slow Ulrich Schreiner
2007-08-01 16:41 ` Avi Kivity
     [not found]   ` <46B0B7D0.9080203-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-08-01 19:45     ` Ulrich Schreiner
     [not found]       ` <46B0E2F0.1070701-sZDnKEZIvs8b1SvskN2V4Q@public.gmane.org>
2007-08-02  8:24         ` Avi Kivity
     [not found]           ` <46B194C5.5040508-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-08-02 19:31             ` Ulrich Schreiner
2007-08-07  7:20             ` Ulrich Schreiner
2007-08-07  7:44               ` Dor Laor
     [not found]                 ` <64F9B87B6B770947A9F8391472E032160D17A0EA-yEcIvxbTEBqsx+V+t5oei8rau4O3wl8o3fe8/T/H7NteoWH0uzbU5w@public.gmane.org>
2007-08-07  9:43                   ` Ulrich Schreiner [this message]
2007-08-07 11:32                     ` Luca
2007-08-07 11:51                     ` Dor Laor
     [not found]                       ` <64F9B87B6B770947A9F8391472E032160D17A197-yEcIvxbTEBqsx+V+t5oei8rau4O3wl8o3fe8/T/H7NteoWH0uzbU5w@public.gmane.org>
2007-08-07 12:08                         ` Luca
     [not found]                           ` <68676e00708070508w3d9e5ab8gd26263c44bf59f0d-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2007-08-07 12:30                             ` Dor Laor
     [not found]                               ` <64F9B87B6B770947A9F8391472E032160D17A1C2-yEcIvxbTEBqsx+V+t5oei8rau4O3wl8o3fe8/T/H7NteoWH0uzbU5w@public.gmane.org>
2007-08-07 12:50                                 ` Ulrich Schreiner
2007-08-07 14:38                                 ` Dong, Eddie
     [not found]                                   ` <10EA09EFD8728347A513008B6B0DA77A01E45A1D-wq7ZOvIWXbNpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-08-07 14:50                                     ` Dor Laor
2007-08-07 20:49                             ` Luca Tettamanti
     [not found]                               ` <20070807204922.GA27976-sTXFmx6KbOnUXq0IF5SVAZ4oGUkBHcCu@public.gmane.org>
2007-08-08  6:28                                 ` Ulrich Schreiner
2007-08-07 12:25                         ` Ulrich Schreiner
2007-08-09 23:23 ` Matthew Kent
2007-08-10  0:09   ` Matthew Kent
2007-08-10  5:32     ` Ulrich Schreiner
2007-08-10  6:39     ` Ulrich Schreiner
2007-08-16  9:56   ` 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=1186479806.3370.22.camel@vaio \
    --to=ulrich.schreiner-szdnkezivs8b1svskn2v4q@public.gmane.org \
    --cc=avik-atKUWr5tajBWk0Htik3J/w@public.gmane.org \
    --cc=dor.laor-atKUWr5tajBWk0Htik3J/w@public.gmane.org \
    --cc=kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
    /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.