Slow KVM Virtual Machine Performance Solved - Choose the right architecture with the CPU flag

I am running a 64-bit host and was running a 32-bit XP guest which was crawling no matter what I was doing with it,in fact it frequently used 100% CPU power while having no real work load.  I experienced with this other guests and wondered why KVM was slow compared to say Xen or Virtualbox.

This is because you need to use the "-cpu" flag.

For a full list of options run:

/usr/libexec/qemu-kvm -cpu \?

x86           qemu64
x86           qemu32
x86         pentium3

The option you need to pass is either "-cpu qemu64" or "-cpu qemu32".  Obviously qemu64 is for 64bit guests and qemu32 is for 32bit guests.

Make sure you specify this or your guest will be extremely slow since it will be emulating the architecture and won't give you native performance if you choose the wrong architecture. 

Also note that if you don't specify the -cpu flag it defaults to your host's architecture (eg. 64bit Centos or 32bit Centos).

So again, the solution is to use the -cpu flag and make sure you specify the correct architecture for the guest.


Tags:

kvm, virtual, architecture, cpu, flagi, xp, frequently, xen, virtualbox, quot, usr, libexec, qemu, pentium, specify, emulating, native, defaults, eg, centos,

Latest Articles

  • Bad Power Supply Issue Story Diagnosing Troubleshooting
  • Getting started with AI (Artificial Intelligence) in Linux / Ubuntu using by deploying LLM (Language Learing Models) using Ollama LLMA
  • microk8s kubernetes how to install OpenEBS
  • Flash LSI MegaRAID 2208 to IT mode in Linux Mint/Debian/Ubuntu
  • LSI MegaRAID in Linux Ubuntu / Centos Tutorial Setup Guide megacli
  • Convert-im6.q16: attempt to perform an operation not allowed by the security policy `PDF' @ error/constitute.c/IsCoderAuthorized/413. convert-im6.q16: no images defined `pts-time.jpg' @ error/convert.c/ConvertImageCommand/3258. solution ImageMagick P
  • Apache PHP sending expires header solution cannot use cache with CDN
  • How to install virt-manager in Mint 22/Ubuntu 22
  • Infiniband Guide
  • python mysql install error: /bin/sh: 1: mysql_config: not found /bin/sh: 1: mariadb_config: not found /bin/sh: 1: mysql_config: not found mysql_config --version
  • FreePBX 17 How To Add a Trunk
  • Docker Container Onboot Policy - How to make sure a container is always running
  • FreePBX 17 How To Add Phones / Extensions and Register
  • Warning: The driver descriptor says the physical block size is 2048 bytes, but Linux says it is 512 bytes. solution
  • Cisco How To Use a Third Party SIP Phone (eg. Avaya, 3CX)
  • Cisco Unified Communication Manager (CUCM) - How To Add Phones
  • pptp / pptpd not working in DD-WRT iptables / router
  • systemd-journald high memory usage solution
  • How to Install FreePBX 17 in Linux Debian Ubuntu Mint Guide
  • How To Install Cisco's CUCM (Cisco Unified Communication Manager) 12 Guide