QEMU for Windows

QEMU is a generic and open source machine emulator and virtualizer. I use it to launch a ISO Operating System images through a guest window on a PC. The host O/S can be Windows, Mac OS X or Linux. The guest operating system runs slower and will lack support for some hardware. To speed up the guest OS use the accelerator KQEMU. This web page provides instructions fro running QEMU from Windows XP.

QEMU is a hands on tool with a challenging learning curve. This web page documents procedures for using QEMU. If you get frustrated with QEMU or wish to try other similar packages, Wikipedia has an article listing various other virtual software packages you can try. For example, VirtualBox is free for personnel and education purposes. Boch is open source software that is similar to QEMU but runs slower.



Finding QEMU Downloads

QEMU is actively developed so there are many different snapshots of QEMU that are available. A snapshot is an updated version QEMU created since the last official release. The official QEMU documentation is available but is a bit out of date.


Finding a download QEMU for Windows can be confusing. There are many different snapshots available for the current release. Plus many QEMU download pages just send you to another web site. On this web page I provide web sites that have active download links.

You can use multiple versions/snapshots of QEMU on the same PC. Just keep them in separate directories. There are no registry settings or system variables used to setup and run QEMU. QEMU is executed through a command window located in the directory of the QEMU snapshot you wish to run.

Now back to downloading QEMU. The QEMU home page identifies the latest version as QEMU v 0.9.1 released on 1/06/08. The latest KQEMU accelerator is Qemu v1.3.Opre11 released 2/06/07. To help sort out which snapshot you can use, try the QEMU forum or just keep reading this web page.

QEMU Home download page has QEMU disk images and source code but no installable windows version. You are referred to the web site QEMU on Windows. This web page references different downloads at several places on the web page. Listed below is a condensed list of QEMU for Windows download sites.


Qemu Downloads:

Qemu on Windows -
Scroll down to Downloads heading
qemu-0.9.0-windows.zip (6,102 KB) from 2/7/07
- A binary package that includes a small Linux from QEMU Linux-test package.
Scroll down to Accelerator heading
Kqemu-1.3.0pre11-install.exe (180 KB) - Installs KQEMU accelerator
Qemu-0.9.0-install.exe (1,688 KB)
- Installs Qemu along with Documentation from 2/7/07.
- It is missing the Linux.img and you still need to execute qemu from the command line

Qemu on Windows by TAKEDA -
QEMU on Windows Ver 0.9.1 (12,832 KB) from 2/4/08
QEMU on Windows Snapshot - qemu-20071213-windows.zip (7,799 KB) snapshot from 12/13/07

Qemu Snapshots - a site with many snapshots of Qemu.
It has the most recent snapshots of QEMU



Setup QEMU to run from Command Line

  1. Download QEMU on Windows Ver 0.9.1 from Qemu on Windows by TAKEDA
  2. Unzip qemu-0.9.1-windows.zip
  3. Rename folder qemu-0.9.1-windows to QEMU
  4. Move folder to C:\

Running the provided Linux Image

  1. On the Windows Tool bar click Start > Run
  2. Enter CMD and press enter
  3. Change to C: drive - Enter C:
  4. Change to directory QEMU - Enter cd \QEMU\
  5. Start up QEMU with provide Linux image - Enter qemu-win
  6. A bunch of configuration messages will fly by. Eventually you will get a prompt with the message "Type 'exit' to halt the system.
  7. Entering EXIT will only reboot the Linux OS
  8. Try a UNIX command such as ls -lr *
  9. To switch to another window press ALT + TAB
  10. To stop the Linux Image while still in the window use CTRL + ALT + 2
  11. Now you are in execute QEMU command window. Type HELP for a quick list of commands. I do not know how to scroll backwards in the window.
  12. To exit this window type QUIT
  13. You might see a message about KQEMU not being activated because it has not been installed.
  14. You have just successful run Linux from Windows XP
  15. To see the commands used to run QEMU enter TYPE qemu-win.bat

KQEMU

KQEMU makes QEMU run faster by running in the background while QEMU is running.
  1. To install it, first download Kqemu-1.3.0pre11-install.exe
  2. Click on the Executable to install it
  3. Shortcuts to KQEMU documentation are added to Start>All Programs>KQEMU
  4. You can run QEMU-WIN.BAT again from C:\QEMU to see the difference
  5. To Stop KQEMU enter the windows command NET STOP KQEMU
  6. To Start KQEMU enter the windows command NET START KQEMU
  7. To uninstall KQEMU, use the shortcut that was added to the start menu

QEMU Documentation

Next to the KQEMU download there is another download Qemu-0.9.0-install.exe. Installing it will provide an older version of QEMU and some much needed documentation on QEMU. The installation puts QEMU in c:\Program Files folder and creates short cuts to Qemu documentation on the Start Menu.

To run this version of Qemu, you will still need to open a command window and change to c:\Program Files\Qemu. This installation is missing the Linux Image and Batch command file you used earlier. It has additional versions of QEMU file that I have not found any use for. The main benefit for installing this QEMU is to get the documentation file short cuts added to the Start Menu. Some documentation is sometimes better than none.


QEMU running MINIX

QEMU can run other OS images. There is a Minix OS image available to run under QEMU. To run this image follow the procedures below.

  1. Download minix204.tar.bz2
  2. Unzip mini204-tar-bz2
  3. Copy minix204.img to C:\QEMU\
  4. Using notepad edit qemu-win.bat
  5. Save as qemu-win-mini.bat
  6. Change linux.img to minix204.img
  7. Save
  8. Open Command window in C:\QEMU as you did earlier
  9. Enter qemu-win-mini.bat
  10. Enter = when prompted for = Start menu
  11. Enter root for noname login:
  12. Try a UNIX command such as ls -lr *
  13. To switch to another window press ALT + TAB
  14. To stop the Linux Image while still in the window use CTRL + ALT + 2
  15. Now you are in execute QEMU command window. Type HELP for a quick list of commands. I do not know how to scroll backwards in the window.
  16. To exit this window type QUIT
  17. You might see a message about KQEMU not being activated because it has not been installed.
  18. You have just successful run Minix from Windows XP

QEMU running DSL

Damn Small Linux (DSL) provides a variety of downloads for each release. The dsl-<version>.iso: is used for liveCD, frugal, or traditional hard drive install. The dsl-<version>-embedded.zip: comes with qemu, for running inside of a host Windows or Linux system.

  1. Download the latest dsl-<version>-embedded.zip. There are a variety of download sites available. I downloaded dsl-4.2.5-embedded.zip
  2. Extract to C:\Linux\DSL
  3. To run execute dsl-base.bat
  4. Now you should have DSL running through a window on your PC.
  5. To switch to another window outside of DSL press ALT + TAB
  6. You wont be able to save any of your work in this setup, So you need cancel out using the CTRL + ALT + 2 and then enter QUIT
  7. The readme.txt file explains the procedures for setting this up.
  8. To save your DSL QEMU session, a virtual drive must be created first
  9. Open Command Window
  10. Switch to C: drive
  11. CD Linux\DSL\QEMU
  12. Execute qemu-img.exe create harddisk 128M
  13. C:\Linux\DSL\qemu>qemu-img.exe create harddisk 128M
    Formating 'harddisk', fmt=raw, size=131072 kB
  14. Execute 1st-boot.bat
  15. Format the virtual drive using the command: mke2fs /dev/hdb
  16. Answer Y to proceed
  17. Enter these following commands:
  18. # mount /mnt/hdb
    # mkdir /mnt/hdb/mydsl
    # mkdir /mnt/hdb/mydsl/modules
    # cp /KNOPPIX/lib/modules/2.4.31/kernel/drivers/block/cloop.o /mnt/hdb/mydsl/modules/.
    # shutdown -h now
  19. When DSL is halted, stop QEMU session by pressing CTRL + ALT + 2 and then entering QUIT
  20. Now start DSL boot using dsl-vhd.bat to start your use of DSL/QEMU with a Virtual Hard Drive System
  21. Select the recommended settings. For video resolution I choose 1024x768x16. Select PS mouse because my mouse would not work even though it is a USB mouse. Maybe QEMU makes it look like a PS2 mouse to DSL.
  22. When you are ready to exist click DSL on lower left corner > Exit > Exit Options > Shutdown > OK

Summation

Completing these exercises demonstrated that your PC can use QEMU to run Linux as a guest OS on your PC. Congratulations. There are other images available from FreeOsZoo. The commands used to getting them to run will vary. For additional help you can use QEMU forum.


GUI's for QEMU


For help is running QEMU, GUI front-ends are available. A GUI Front-end is used to make running QEMU easier. QEMU has many parameters that are used to run it. A GUI takes care of the complexity in formatting the proper command.

QEMU Manager - provides a GUI front-end to QEMU and KQemu.
  • Qemu Manager v5.0 (Feb 2008) with Qemu 0.9.0/0.9.1 and KQEMU Support
  • Qemu Manager v5.0 (Feb 2008) with Qemu 0.9.0/0.9.1 and KQEMU Support (Zip File)
  • Documentation - download only for v4 so far
The include Qemu Snapshot is from 2/23/08

Other GUI
  • QGui - QEMU Launcher - requires VB Runtimes.
  • QtEmu - graphical user interface for QEMU written in Qt4
  • Qemulator - full featured emulation suite for the qemu virtual engine for Ubuntu Linux


Using Qemu Manager GUI to run QEMU

Qemu Manager is the easiest of the GUI's to use because it was the only one I got to run. Installing it provides QEMU, KQEMU accelerator, documentation, and a GUI to execute QEMU.


QEMU Manager has two versions available comes in two formats to install it. The v5 includes both the 9.0 and 9.1 version of QEMU. For these procedures download the Qemu Manager v5.0 (Feb 2008) with Qemu 0.9.0/0.9.1 and KQEMU Support.


QEMU Installation
  1. Download Qemu Manager v5.0 Zipped
  2. Extract to C:\QEMU
  3. Replace any duplicate files
  4. Startup by clicking QemuManager.exe

QEMU Manager First Run Wizard settings:
  1. Qemu Manager Language > English
  2. Default Keyboard > en-us
  3. Enable > Install & Enable KQEMU Accelerator Driver Support
  4. Enable > Enable the Qemu Manager QEMU Client by default.
  5. Click OK

Start up QEMU manager if it is not already running. This product installs KQEMU again even if it was installed previously (KQEMU above). The two installations of KQEMU mentioned are oblivious to each other even though they use the same file.

  1. Create Virtual machine. Click Red box with + in it.
    1. Name> Linux
    2. Operating System > Linux Distribution
    3. Virtual Machine Memory > 256
    4. Drive Size > 300 MB
    5. Drive Type > Qcow2
    6. Hardware Type > Standard 32 Bit PC (0.9.1) QMQC
    7. Click Create
    8. Select Linux
    9. Click Drives Tab
    10. Double Click Hard Drive 0
    11. Click ... button and select file C:\qemu\Linux.img
    12. Click Open, Click OK

  2. Test Image
    1. On menu bar, click Options
    2. Click Disable the Qemu Manager QEMU Client Support. This GUI blocks the bottom this image command line.
    3. Click Green Arrow Icon
    4. You see a bunch of configuration messages
    5. Finally you will get a command line
    6. Enter a test UNIX command such as ls -lr \*
    7. To switch from the Linux window to other pres ALT + TAB
    8. To exit Linux press CTRL + ALT + 2
    9. To exit QEMU type Q

This tool works well if you can provide an image to to run under QEMU. I don't know why I create an empty image file just to replace it with an existing file. In Version 4 I could specify an existing image when creating a VM.


Additional Setups



Using QEMU to run Puppy Linux

The PupWinQe tool allows you to run the Puppy Linux through a window on Windows XP. Its home page provides detail instructions on using this tool. For additional information see the forum topic PupWinQE.zip Puppy with QEMU in Windows XP.

Steps followed:
  1. For Windows XP, Puppy Linux cannot save its setting on a NTFS drive. Whenever I try, it causes file corruption so I recommend against it.
    1. Download a Puppy Save file. I recommend at least the 254 size file
    2. Extract the pup
  2. Downloaded PupWinQE.zip
  3. Extract PupWinQE.Zip to C:\Puppy
  4. Downloaded puppy-2.17.1-nolzma-seamonkey-fulldrivers.iso 93 MB to C:\Puppy
  5. Edit Puppy.bat and change puppy-2.11-seamonkey.iso to puppy-2.17.1-nolzma-seamonkey-fulldrivers.iso
  6. The instruction says you can run it by executing by clicking on the Puppy Linux shortcut. I get nothing from doing it. So I open a command window, switch to c:\puppy, and execute Puppy.bat
  7. Select Language USA-Central
  8. Picked Xvesa
  9. Pick 800x600x16
  10. Click OK
  11. Congratulations you are now running Puppy Linux
  12. Hint. For this desktop software only use single clicks to execute ICONS
  13. Setup Network Connection
    1. Click Connect Icon
    2. Select Connect to Internet by Network Interface
    3. A driver is loaded automatically
    4. Test Connection by click (eth0)
    5. Click (Test eth0)
    6. You should get the response 'You can proceed to acquire an IP Address'
    7. Click (Auto DHCP)
    8. If Successful Click (Yes) to save Network Configuration
    9. Click (Exit)
  14. Test Internet Connection
    1. Click Browse - It may take a little while to come up
    2. Scroll done and click on Forum link
    3. There you are know browsing the world wide web
    4. Try out other web sites such as www.yahoo.com
    5. I found that none of the audio worked on a news video I clicked
  15. Exiting
    1. To exit click shutdown
    2. Select Power Off
    3. Follow the directions if you wish to save your setup along with anything you did.
    4. It took a while to create pup_save.2fs
Trying Other Images
  1. Download qemu-puppy-2.17-1.tar.gz

Puppy Linux provides instructions for using Puppy Linux on a USB Drive with QEMU. The idea is to create portable OS on a USB drive. I found it an easy to get an ISO image for Linux. For Windows OS there are tools to generate them from installation CD. There are several versions of Linux that are still small but provide a full desktop. Puppy Linux is only 96 mb and load entirely into memory so its a good candidate for trying out QEMU on a ISO file.


http://www.erikveen.dds.nl/qemupuppy/



Additional Info



QEMU for Puppy Linux
  • There is a few ways to make this happen
  • This site seems to provide everything that is needed. I was able to find a missing file that the new QEMU.EXE needs. There is even a version for Win 98

If you find you need some additional help he are some sites:

Last Updated:Monday, 21-Jul-2008 19:33:34 CEST