How to install Windows Vista in QEMU

This page details how to install Windows Vista in QEMU. Windows Vista is an operating system created by Microsoft, released on November 8, 2006. Support ended on April 11, 2017.
Prerequisites
QEMU
You will need QEMU installed.
Windows Vista ISO
You'll need a Windows Vista ISO for this guide. You can:
- You can use a physical disc
- Download the Vista ISO from Computernewb (64-bit)
- Source an ISO from elsewhere
Installation
Creating the Disk Image
First, open a command window and create a disk image for the VM using a command like the following.
qemu-img create -f qcow2 winvista.qcow2 40G
40G can be replaced with however big you want the hard drive to be (with G standing for Gigabytes).
Starting QEMU
You can now start up QEMU with a command like the following:
qemu-system-x86_64 -M q35,usb=on,acpi=on,hpet=off -m 4G -cpu host,hv_relaxed,hv_frequencies,hv_vpindex,hv_ipi,hv_tlbflush,hv_spinlocks=0x1fff,hv_synic,hv_runtime,hv_time,hv_stimer,hv_vapic -smp cores=2 -accel kvm -drive file=winvista.qcow2 -device usb-tablet -device VGA,vgamem_mb=128 -nic user,model=e1000 -monitor stdio -cdrom "Windows Vista SP2 x64.iso"
Windows Vista was somewhat infamous for its beefy system requirements at the time, so at least 2 GB of RAM should be used (technically, it can run on as low as 512 MB, but that is not recommended). Here, we use 4 GB of RAM. We also enable Hyper-V enlightenments on the CPU to improve performance.
Installing Windows
From here, the installation is pretty straightforward. Agree to the license, select a custom install to the unallocated space, and wait for it to install. The OS should install pretty quick on newer systems.
Post-install
Invoking QEMU
After installing, you should remove the same QEMU command as before, except the -cdrom ... argument should be removed.
Browsers
Despite both Firefox and Chromium dropping support for Vista quite a while ago, there are maintained forks of modern versions of both of these browsers that work on Vista.
Supermium
Supermium is a Chromium fork that works in Vista. It needs around 2 GB of RAM to function.

- Open Internet Explorer (or whatever browser you have installed)
- Navigate to
http://win32subsystem.live/supermium/legacy/ - Download the Setup executable for your VM's bit width and run it
- You will get a few options in the setup. All of them are optional but I recommend installing the Noto Emoji font and creating shortcuts for Supermium. Hit OK
- If all went well, Supermium should be working!
r3dfox
r3dfox is a Firefox fork that works in Windows Vista. It requires Windows Vista SP2 or later.

- Download the following files onto your host:
- KB971644 ISO
- VCRedist AIO for Vista
- The latest r3dfox installer for your bit width
- Insert the KB971644 ISO (change ide2-cd0 KB971644x64.iso) into your VM
- Navigate to the CD drive and install all 4 .msu update files on the ISO
- Reboot your VM
- On your host, pack both the r3dfox installer and VCRedist zip onto an ISO file
- On Windows, you can use ImgBurn
- On Linux, you can use the following command: mkisofs -o r3dfox.iso r3dfox-(version).en-US.win(arch).installer.exe VisualCppRedist_AIO_x86_x64_61.zip
- You can also get the files onto the VM a different way.
- Insert the ISO file into the VM (change ide2-cd0 r3dfox.iso)
- Extract and install the VCRedist AIO contained on the CD
- Finally, run the r3dfox installer from the CD and install it
- If all went well, r3dfox should be running!
Activation
Windows Vista can be activated using Massgrave's Microsoft Activation Scripts:
- Download and install PowerShell 2.0 (32-bit/64-bit) onto your VM.
- Download and install the .NET Framework 3.5 SP1 Runtime onto your VM.
- Download the latest MAS_AIO.cmd and run it
- Select 3 for TSForge Activation, followed by 1 to activate Windows.
- You should now have an activated copy of Windows Vista.
Speed increase
If you are running without KVM then it is highly recommended that you turn off the "Aero" theme enabled by default on Windows Vista, and use the Classic theme instead. This greatly improves performance. To do that, right click on the desktop, click "Personalization", Themes, click on the dropdown box, and choose Windows Classic. Hit Apply then hit OK.