This post is about setting up
qemu on Windows 10 and running Ubuntu on it. Just to show that there is another alternative beside virtualbox and vmware player. Even though KVM doesn’t work on windows it is still a solid alternative.
To install download the 64-bit binaries for windows. It’s way less hectic than compiling your own from the source, and I didn’t even attempt to do that. Add the installed location
C:\Program Files\qemu to the windows path.
Once installation and path setting is done try to run
cmd. You will see that qemu ultimately fails, complaining that there is no bootable image. So let’s get that bootable media for qemu.
Get the desktop image from Ubuntu website
Create the hard disk image for qemu in a format it understands and get it ready for Ubuntu installation.
qemu-img create -f qcow2 ubuntu-desktop.img.qcow2 50G
#[Output] Formatting 'ubuntu-desktop.img', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=32212254720 lazy_refcounts=off refcount_bits=16
To install Ubuntu, run
qemu by setting the formatted file as HDD and the downloaded
cdrom. Once you run this command the same window will appear and this time it’ll find a bootable media, the
cdrom. If the window goes black, try again and this time click inside and press enter.
qemu-system-x86_64 -hda ubuntu-desktop.img.qcow2 -m 4G -net nic -net user -cdrom ubuntu-20.04.2.0-desktop-amd64.iso -accel whpx
Once installation is done, power off the machine instead of restart.
Now, run the
qemu without anything in the
qemu-system-x86_64 -hda ubuntu-desktop.img.qcow2 -m 4G -net user -net nic -accel whpx
Once system boot is done, try to open firefox and access some website.