Most of the time, one operating system per computer is enough. But on occasion, you might want to boot up a second operating system for security reasons, testing purposes, or compatibility with specific software. Technical details typically restrict that alternate OS to a single PC, however. You can only install an OS in a single location after all.
But using a fork of Oracle's popular VirtualBox virtualization software, known as Portable VirtualBox, you don't have to limit secondary operating systems to a single computer or boot it up separately from Windows. Instead, you can pack it onto a portable USB drive and load it up on any PC while Windows runs in the background, like a virtualized version of the Windows to Go option found in Windows 8 Enterprise.
Portable VirtualBox is fairly easy to set up, though it does require attention to a few key details. We'll walk you through it, and outline some of the main concerns with running a virtual machine on a portable USB drive.
Things to consider
The one major caveat with Portable VirtualBox is that it requires administrator privileges to run. That shouldn't be a problem if you're setting this up at home, but it's not the most practical solution for enterprise users, because the IT manager would need to be around to plug in a password.
VirtualBox also consumes a certain amount of hard drive space and memory--both of which you can adjust when setting it up--as well as processing power. That means you'll need a big-enough USB drive to contain whatever operating system you install--1.5GB for Windows XP and 5GB for Ubuntu, to name a couple of examples--and you might have problems using a virtual machine on a five year-old netbook with limited resources.
Also, keep in mind that VirtualBox doesn't come with any actual operating systems. You'll still need to supply your own installation files, and in the case of Windows, your own serial key to validate your copy of the software. (If you're looking for something free to mess around with in VirtualBox, Ubuntu should do the trick.)
Finally, consider reformatting your USB drive as an NTFS file system, because the FAT32 system used by some USB drives will limit file sizes to 4GB. To reformat a drive, right-click it in Windows Explorer, select Format and choose NTFS under the File System menu. This will delete all the drive's contents, so make doubly sure you're formatting on the USB drive you intend to use, and not any other drive on your system.
Setting up Portable VirtualBox
Once your USB drive is ready, download Portable VirtualBox. Open the file and extract the software to your USB drive. (You can also extract the files to another directory, and then paste the newly created folder into your USB drive.) Now, look in that directory and open "Portable-VirtualBox.exe."
A window will pop up, with a huge "Download installation files of VirtualBox" button at the top. Click this button. While you're waiting, click the "Extract files" box for 32-bit or 64-bit operating systems, depending on the computers you're planning to use with VirtualBox. You can check both boxes, but this will take up more space. Check the"Start Portable-VirtualBox after the extract and/or compress" box.
Here's one potentially confusing part of this process: Once the files are finished downloading, click the OK button in the bottom left corner. Do not click the Exit button on the bottom right corner, and do not click the new VirtualBox.exe file that has appeared in your installation directory. (If you see an installation wizard, you're on the wrong track. Re-open Portable-VirtualBox.exe, and use the Search button to select that VirtualBox.exe file, then click OK.)
Be patient after clicking the OK button. It can take several minutes for Portable VirtualBox to extract and install the necessary files, and there's no progress bar to let you know how things are going. You may even hear a few error-like Windows sounds during the installation. Ignore those! If you try to quit prematurely, things can crash and you may have to start all over again. Just sit tight until you see the VirtualBox splash screen pop up.
Once the software is installed, it should open on its own, though it may prompt you to exit and re-open the app to ensure everything's working properly. You can do this by opening the notification area of the Windows taskbar, right-clicking the Portable VirtualBox button, and clicking Quit. You can also tweak settings such as network support from this same right-click menu. (Network and USB support are disabled by default.)
To re-open Portable VirtualBox, click on the same Portable-VirtualBox.exe file on your flash drive--the one that previously led to the setup screen. This time, it'll take you straight to the VirtualBox software.
From here, it's VirtualBox as usual. We won't get into the nitty-gritty of how to set up a virtual machine, but you can check out our detailed instructions on installing Windows XP, Windows 8, Android or SteamOS through VirtualBox. Any of those tutorials should give you a good sense of how Oracle's virtualization software works.
Once you've set up a virtual machine, you can pop that USB stick into any Windows PC and open Portable-VirtualBox.exe, letting you run your chosen OS almost anywhere, and free of the file retention issues associated with ephemeral Linux live CDs. Pat yourself on the back for fitting all kinds of alternative operating systems and aging software in the palm of your hand.
This story, "Have operating system, will travel: How to run virtual machines from a flash drive" was originally published by PCWorld.