• qemu vm start slower on host with kernel 4.12 in comparison with 4.9

    Hi there!

    I’m playing currently with QEMU KVM VGA passthrough with OVMF.
    I really enjoy Antergos stable Gnome experience, but one fact that annoying me and stopping me use Antergos as my default desktop OS on my PC(on laptop I use it because I don’t need QEMU here) is that QEMU virtual machine start is slow in comparison with Debian systems.
    I made some testing and it looks like time taken to show windows desktop on 4.12 takes twice as much as on 4.9.
    On 4.9 it is around 20 seconds when on 4.12 it is about 40

    the main difference I’ve noticed it time to show OVMF logo during boot
    in 4.12 it takes 2 much time
    when on 4.9 it is displayed almost immediately

    But what has been changed that has such dramatic (doubled performance in starting VM) ?

    I’m using the following command to run VM

    x86_64-softmmu/qemu-system-x86_64 -monitor stdio \
    	-serial none \
    	-parallel none \
    	-nodefaults \
    	-nodefconfig \
    	-no-user-config \
    	-enable-kvm \
    	-name "Windows 10" \
            -M q35 \
    	-cpu host,kvm=off,hv_vapic,hv_time,hv_relaxed,hv_spinlocks=0x1fff,hv_vendor_id=sugoidesu \
    	-smp sockets=1,cores=4,threads=2 \
    	-m 8192 \
    	-mem-prealloc \
            -usb \
            -device usb-ehci,id=ehci \
            -device usb-host,bus=ehci.0,hostbus=1,hostaddr=3 \
    	-machine pc,accel=kvm,kernel_irqchip=on,mem-merge=off \
     	-drive if=pflash,format=raw,file=./windows10.bios,readonly \
            -drive if=pflash,format=raw,file=./windows10_vars.fd \
    	-rtc base=localtime,clock=host,driftfix=none \
    	-boot order=c \
            -net nic,vlan=0 \
            -net user,vlan=0 \
    	-drive if=virtio,file=/dev/vms/windows10,format=raw,cache=none \
    	-drive if=virtio,file=/mnt/DATA2/KVM/windows10-data.qcow2,format=qcow2 \
    	-nographic \
    	-device vfio-pci,host=01:00.0,multifunction=on \
    	-device vfio-pci,host=01:00.1 \
            -usbdevice host:1532:0202 \
            -usbdevice host:09da:5dd6
  • Hi,

    You can always try to use the linux-lts package… it’s 4.9.41 at the time of writing this.

  • Actually I’m doing this right now.
    But eventually 4.9 will became old and newer 4.xx version of LTS will be available, and if it will be based on the same 4.12 we will get doubled performance penalty with qemu.
    That is why I would like to figure out what is going on bad with new kernels.

kernel152 qemu5 host5 slower2 Posts 3Views 675
Log in to reply
Bloom Email Optin Plugin

Looks like your connection to Antergos Community Forum was lost, please wait while we try to reconnect.