Why multiprocessor guest has slow performance and many "Rescheduling interrupts"?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello, I have server platform S5520UR, 2x Intel Xeon E5520 with Debian Squeeze.
In kvm guest with debian, I execute gbuk for firebird  and he working
quickly on 1 cpu guest, than 4.
vmstat show that with 1 cpu guest 300/s interrupts, but in 4 cpu guest
interrupts over 12000/s
If run gbuk in host than interrupts ~500/s
Why multiprocessor guest has slow performance and many "Rescheduling
interrupts"?

uname -a
Linux vm 2.6.32-5-amd64 #1 SMP Wed Jan 12 03:40:32 UTC 2011 x86_64 GNU/Linux

Hyper Threading off.

processor    : 0
vendor_id    : GenuineIntel
cpu family    : 6
model        : 26
model name    : Intel(R) Xeon(R) CPU           E5520  @ 2.27GHz
stepping    : 5
cpu MHz        : 2261.597
cache size    : 8192 KB
physical id    : 0
siblings    : 4
core id        : 0
cpu cores    : 4
apicid        : 0
initial apicid    : 0
fpu        : yes
fpu_exception    : yes
cpuid level    : 11
wp        : yes
flags        : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge
mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe
syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts rep_good
xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est tm2
ssse3 cx16 xtpr pdcm dca sse4_1 sse4_2 popcnt lahf_lm tpr_shadow vnmi
flexpriority ept vpid
bogomips    : 4523.19
clflush size    : 64
cache_alignment    : 64
address sizes    : 40 bits physical, 48 bits virtual
power management:


### GUEST 4 CPU & GBAK

LC_ALL=C PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
HOME=/ QEMU_AUDIO_DRV=none /usr/bin/kvm -S -M pc-0.12 -cpu
qemu64,+sse4.2,+sse4.1,+cx16,+ssse3,+ht,+ss,+acpi,-svm -enable-kvm -m
4096 -smp 4,sockets=4,cores=1,threads=1 -name firebird -uuid
e324d7cf-63e8-bece-da69-915f3b60cd4e -nodefaults -chardev
socket,id=monitor,path=/var/lib/libvirt/qemu/firebird.monitor,server,nowait
-mon chardev=monitor,mode=readline -rtc base=localtime -boot c -drive
file=/dev/mapper/infor-sys,if=none,id=drive-virtio-disk0,boot=on,format=raw,cache=none
-device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,id=virtio-disk0
-drive file=/dev/vm3-vg0/firebird-backup,if=none,id=drive-virtio-disk1,format=raw,cache=none
-device virtio-blk-pci,bus=pci.0,addr=0x5,drive=drive-virtio-disk1,id=virtio-disk1
-drive if=none,media=cdrom,id=drive-ide0-1-0,readonly=on,format=raw
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0
-device rtl8139,vlan=0,id=net0,mac=00:00:00:00:00:00 -net
tap,vlan=0,name=hostnet0 -chardev pty,id=serial0 -device
isa-serial,chardev=serial0 -usb -device usb-tablet,id=input0 -vnc
127.0.0.1:0 -vga cirrus -device
virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6

vmstat 1
procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu----
 r  b   swpd   free   buff  cache   si   so    bi    bo   in   cs us sy id wa
 3  0      0 3936060   2808  50236    0    0    22     1   81  188  0  0 99  0
 1  0      0 3932836   2816  52308    0    0  1024    12 10895 42583 12 12 76  0
 2  0      0 3930092   2816  54200    0    0   768     0 12262 35393  9  8 83  0
 1  0      0 3926992   2816  56104    0    0   896     0 12504 37866  8 16 76  0
 1  0      0 3924248   2816  57896    0    0   768     0 12635 36196 11 18 71  0
 2  0      0 3921488   2816  59672    0    0   768     0 12137 34850
9 13 78  0


cat /proc/interrupts
           CPU0       CPU1       CPU2       CPU3
  0:         36          1          0          0   IO-APIC-edge      timer
  1:          0          2          3          2   IO-APIC-edge      i8042
  6:          0          1          0          1   IO-APIC-edge      floppy
  8:          0          0          0          1   IO-APIC-edge      rtc0
  9:          0          0          0          0   IO-APIC-fasteoi   acpi
 10:          6          5          5          7   IO-APIC-fasteoi
uhci_hcd:usb1
 11:          0          0          0          0   IO-APIC-fasteoi   virtio3
 12:         30         33         30         33   IO-APIC-edge      i8042
 14:          0          0          0          0   IO-APIC-edge      ata_piix
 15:         21         20         22         21   IO-APIC-edge      ata_piix
 24:          0          0          0          0   PCI-MSI-edge
virtio0-config
 25:       1932       1938       1946       1943   PCI-MSI-edge
virtio0-input
 26:          0          0          0          1   PCI-MSI-edge
virtio0-output
 27:          0          0          0          0   PCI-MSI-edge
virtio1-config
 28:        598        602        614        590   PCI-MSI-edge
virtio1-requests
 29:          0          0          0          0   PCI-MSI-edge
virtio2-config
 30:        187        202        178        188   PCI-MSI-edge
virtio2-requests
NMI:          0          0          0          0   Non-maskable interrupts
LOC:      13408      17361      11917      10557   Local timer interrupts
SPU:          0          0          0          0   Spurious interrupts
PMI:          0          0          0          0   Performance
monitoring interrupts
PND:          0          0          0          0   Performance pending work
RES:     407852     316807     142502      53772   Rescheduling
interrupts  <<<<<< quick increase
CAL:         36         32         40         42   Function call interrupts
TLB:        455        463        467        479   TLB shootdowns
TRM:          0          0          0          0   Thermal event interrupts
THR:          0          0          0          0   Threshold APIC interrupts
MCE:          0          0          0          0   Machine check exceptions
MCP:          2          2          2          2   Machine check polls
ERR:          0
MIS:          0


4xCPU

processor    : 0
vendor_id    : GenuineIntel
cpu family    : 6
model        : 2
model name    : QEMU Virtual CPU version 0.12.5
stepping    : 3
cpu MHz        : 2261.596
cache size    : 4096 KB
fpu        : yes
fpu_exception    : yes
cpuid level    : 4
wp        : yes
flags        : fpu de pse tsc msr pae mce cx8 apic sep mtrr pge mca
cmov pse36 clflush mmx fxsr sse sse2 syscall nx lm rep_good pni ssse3
cx16 popcnt hypervisor lahf_lm
bogomips    : 4523.19
clflush size    : 64
cache_alignment    : 64
address sizes    : 40 bits physical, 48 bits virtual
power management:

#### GUEST 1 CPU & GBAK

vmstat 1
procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu----
 r  b   swpd   free   buff  cache   si   so    bi    bo   in   cs us sy id wa
 2  0      0 3926912   2780  58440    0    0   529    14   96 3032  6  6 83  5
 2  0      0 3922060   2780  61372    0    0  1408     0  277 30910 51 49  0  0
 1  0      0 3916844   2788  64820    0    0  1408    12  281 30770 53 47  0  0
 1  0      0 3912000   2788  67764    0    0  1408     0  277 30841 48 52  0  0
 2  0      0 3907288   2796  70700    0    0  1408    24  285 30846 44 56  0  0
 2  0      0 3902220   2796  74044    0    0  1280     0  276 30890 51 49  0  0

#### HOST 8 CPU & GBAK

vmstat 1
procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu----
 r  b   swpd   free   buff  cache   si   so    bi    bo   in   cs us sy id wa
 2  0   7168 14189732 302768 34404528    0    0  2432    24  621
107481  7  6 87  0
 1  0   7168 14180556 302768 34410160    0    0  2560     6  617
110398  8  7 85  0
 1  0   7168 14172124 302768 34415664    0    0  2432     2  593
111195  7  7 86  0
 1  0   7168 14162452 302768 34421732    0    0  2688     0  617
116094  5  4 91  0
 1  0   7168 14153524 302768 34427364    0    0  2560     0  607
116056  7  7 87  0


More stats here http://pastebin.com/vy5WtvU4

Thanks for any advice.

-- 
Konstantin
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux