Carry a virtual Linux machine with you wherever you go.
Theoretically, a bootable USB stick with a Linux distribution lets you carry your Linux desktop with you without installing any software on the host machine. In practice, however, your Linux-on-a-stick might not be as universal as advertised. Sometimes you must ask the permission of the owner of the computer you are using, and many PC owners are reluctant to let their friends boot to a totally different operating system. In some cases, you might need to manually reconfigure the BIOS to support a USB boot. Many Internet cafes do not even let you reboot the system, so booting into Linux simply isn't an option.
An easy solution to this problem is a virtual machine based on the popular QEMU emulator [1]. With QEMU, you can install a Windows version of QEMU on a USB stick, create a Linux-based virtual machine, and run Linux as a virtual system inside Windows.
The excellent Qemu Manager [2] tool lets you turn your USB stick into a portable computing environment (Figure 1). Qemu Manager wraps the QEMU functionality into a sleek and user-friendly graphical interface that lets you create, manage, and run virtual machines with consummate ease. Installing Qemu Manager is as simple as downloading the zipped version of the tool, unpacking it in a folder on the USB stick, and double-clicking on the QemuManager.exe executable to launch Qemu Manager.
Oracle VM VirtualBox Extension Pack. Free for personal, educational or evaluation use under the terms of the VirtualBox Personal Use and Evaluation License on Windows, Mac OS X, Linux and Solaris x-86 platforms.
Figure 1: Using the portable version of Qemu Manager, you can run your favorite Linux distro inside Windows.
Qemu Manager boasts an easy-to-use interface that provides access to almost all of QEMU's features (Figure 2). If you've ever tried to work with virtual machines in any other virtualization software like VirtualBox or VMware Player, you'll feel at home with Qemu Manager. The main toolbar at the top of Qemu Manager's window contains buttons that allow you to create, delete, and launch virtual machines. In addition, the Create Disk Image button lets you create an image from a CD or DVD. This feature can come in handy if you have to generate an ISO image to use with a virtual machine from a system CD or DVD. To create and manage so-called VM stores or virtual machine repositories containing configuration files and disk images, use the Manage VM Stores button. Finally, the Add/Remove Hardware button allows you to add and remove hardware components in a virtual machine. The right pane of the main Qemu Manager window contains three sections: Hardware, where you manage and configure the virtual machine's hardware modules; Drives, for managing the virtual machine's hard disks, optical drives, and snapshots; and Advanced, where you can tweak QEMU's advanced settings. The left pane lists the current virtual machines.
Figure 2: Qemu Manager makes it easy to create, manage, and run virtual machines.
Working with Virtual Machines
Creating a new virtual machine in Qemu Manager is very easy. Before you press the Create new VM button, though, you need to download an ISO image of the Linux distribution you want to use with Qemu Manager. Alternatively, you can use the Create Disk Image button to convert the inserted CD or DVD into an ISO image. Place the downloaded or generated ISO image into the Media folder inside your Qemu Manager folder on your USB stick. It is important that you keep all .iso images in this folder so your virtual machine can find them no matter which letter Windows assigns to the USB stick. Now you can press the Create new VM button, which starts a wizard that guides you through the process of creating a virtual machine (Figure 3). Setting up a new virtual machine only requires you to specify a few basic settings, such as guest operating system (Linux Distribution), a platform for the virtual machine (choose Standard x86/x64 PC if you plan to use the virtual machine on Intel or AMD-based machines), memory size, and a virtual disk image. The last two settings depend on the Linux distribution you want to use with the virtual machine; for example, running lightweight distros like Puppy Linux or SliTaz will require about 128MB RAM and a relatively small hard disk. When setting up a virtual disk image, you have the option of encrypting it, which provides an additional level of security.
Figure 3: Using the wizard to create a new virtual machine.
If you need to, you can always modify the virtual machine's settings specified in the wizard in the Hardware section. Editing the settings can be useful when you need to tweak the virtual machine to run optimally on the computer at your disposal. For example, if you run the virtual machine on a computer with a dual-core processor, you can adjust the No of CPUs setting accordingly. Does the host machine use a 64-bit processor? Then set the CPU Type option to 64-bit. When creating a virtual machine, you might also want to enable the Qemu Manager QEMU Client, which adds a few useful features like the ability to manage physical and virtual drives, send the Ctrl+Alt+Del command to the guest system, pause and resume the virtual machine, and manage snapshots.
Before you launch the created virtual machine, you have to specify the .iso image as the boot device. In the main Qemu Manager window, switch to the Drives section, double-click on the CD-ROM item, select the .iso image, and press OK. Now double-click on the Boot Drive item and select CD-ROM from the Boot From drop-down list. Later, if you decide to install the Linux system on the virtual hard drive, you can remove the .iso image and set the Boot Drive to Hard Disk.While you are at it, you can tweak other settings, too. For example, if you want to exchange files between the guest and host systems, you can enable the file transfer feature. File transfer occurs through a local FTP server that the guest system then accesses with the use of an FTP client. To enable the file transfer feature, choose File Transfer | Configure File Transfer Server in the main menu (Figure 4). If you want to share a specific folder, tick the Share The Following Folder Only checkbox and select the desired folder. Once you've configured and saved the server, choose File Transfer | Start File Transfer Server in the main menu to start the server. Then you can access the FTP server from your Linux system running in QEMU with the 10.0.2.2 address and QEMU as both username and password.
Once the virtual machine is configured, fire it up with the Launch Selected VM button on the main toolbar. If you enabled the Qemu Manager QEMU Client, you can control the virtual machine session with the buttons on the top toolbar. Most of these buttons are self-explanatory except, perhaps, VM Snapshot Management.
Like other virtualization systems, QEMU allows you to take a snapshot of the virtual machine's current state. Then you can use the snapshot to launch the virtual machine in exactly the same state you left it. The VM Snapshot Management button provides access to commands that let you take a snapshot of the virtual machine, as well as load and delete existing snapshots.
Before you create and run a virtual machine, keep in mind that QEMU can act as either an emulator or a virtualizer. When used as an emulator, QEMU 'mimics' the Pentium II processor, dynamically translating the guest application's calls into native instructions. Although QEMU offers decent performance by emulator standards, it is still too slow to be genuinely useful. When used as a virtualizer, QEMU achieves near native performance by executing the guest code directly on the host processor. The virtualizer mode is by far the best way to use QEMU, but it requires the KQEMU accelerator software on the host machine. Fortunately, Qemu Manager makes it extremely easy to install the KQEMU component. Simply choose the Options | Install KQEMU Accelerator command from the main menu to turn QEMU into a virtualizer. Once you're finished using your virtual machine, choose the Uninstall KQEMU Accelerator command.
Final Word
The QEMU/Qemu Manager combo makes a perfect solution for running a Linux environment inside Windows. Using Qemu Manager, you can easily create and manage virtual machines and stay productive, even when you only have access to a Windows machine. Even if you carry your notebook or netbook with you, having a ready-to-use virtual machine on a USB stick provides an excellent backup option.
QEMU: http://www.nongnu.org/qemu/
Qemu Manager: http://www.davereyn.co.uk/
Buy this article as PDF
Buy Linux Magazine
UK / Australia
Related content
QEMU 2
The new version of QEMU is a free virtualization solution that offers excellent stability and flexibility. We show how to deploy QEMU 2 in a Live environment.
QEMU System Emulation
Do you ever wish you could run Linux within Linux? Or how about DOS within Linux? QEMU is an open source application that lets you emulate a complete hardware environment within your Linux system.
KVM
KVM brings the kernel into the virualization game. We’ll explain why the Linux world is so interested in this promising virtualization alternative.
KVM Front Ends
If you want to care for a zoo full of exotic KVM guest systems on your desktop, you could use a little help from a graphical front end.
KVM Storage
KVM has many ways to map virtual disks on the host system. The appropriate choice of disk format has an effect not only on the speed of I/O operations but also on snapshots and backups.
Please enable JavaScript to view the comments powered by Disqus.comments powered by Disqus
WinToUSB portable is the best Windows To Go Creator that allows you to install and run Windows operating system on a USB hard drive or USB flash drive, using an ISO image or CD/DVD drive as the source of installation. Starting from version 2.0, you can clone current Windows OS installation (Windows 7 or later) to a USB drive as a Windows To Go Workspace. WinToUSB also supports creating a bootable WinPE USB drive, it can help you transfer the contents of WinPE to a USB drive and make the drive bootable.
WinToUSB’s key features include:
Easy-to-use wizard interface that provides step-by-step instructions for creating a Windows To Go USB drive.
Creation of Windows To Go from an ISO image file or CD/DVD drive.
Clone an existing Windows OS (Windows 7 or later) to a USB Drive as a Windows To Go Workspace.
Use of a Non-Enterprise Edition of Windows 10/8.1/8/7 to create Windows To Go Workspace.
Creation of Windows To Go on Non-Certified Windows To Go USB Drive.
Support for creating VHD-based/VHDX-based Windows To Go Workspace.
Important notes:
Windows 7 is not completely portable. You may have driver problems when booting on different computers, so highly recommend using Windows 10/8.1/8 to create portable Windows.
Windows 7 does not have built-in USB 3.0 support, so Windows 7 will have to be booted from a USB 2.0 port.
The common USB flash drives are very slow. It takes a long time to install and run Windows from a common USB flash drive, highly recommend using a USB hard disk, a Windows To Go Certified Drives or a SanDisk Extreme CZ80 USB 3.0 Flash Drive to create portable Windows.
Windows To Go drives can be booted on different computers, so you can carry it to anywhere and use it on any computer.
You need to be an administrator on the computer you are installing the WinToUSB on.
Enterprise Edition Features:
Clone current Windows OS (Enterprise edition of Windows 10/8.1/8/7) to a USB drive as a Windows To Go Workspace
Clone current Windows OS which on a dynamic disk to a USB drive as a Windows To Go Workspace
Clone current Windows OS which on a USB disk (Windows To Go USB drive) to other USB drives as a Windows To Go Workspace
Faster Clone Speed
No upgrade prompts
Business usage
Whats New:
Fixed bug: Pre-OS could not be started on some UEFI-based computers
Fixed bug: Failed to clone Windows Server in some cases