Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there any setup that will allow one to plug in and boot via USB (most likely a linux distro) and then bring up Windows XP (or any OS) in a VM?

share|improve this question
up vote 2 down vote accepted

This is not theory. It will definitely work as I have done very similar things before. A linux OS on a usb drive is just as powerful as the full fledged hd. Speed is indeed the only issue.

The basic idea would be to get the live OS on to the usb and allow it to be persistent (changes be made and kept after a restart)

create a bootable partition on the usb drive and rsync all of the data on the live disc over to the usb.. fdisk the usb device and create 2 partitions. one should be bootable and the other should be for all of the changes

then create an ext3 filesystem on the bootable partition ie:

mkfs.ext3 /dev/usbdevice

then create directories.. mount the usb.. mount the iso and rsync the data over to the usbs bootable partition ie:

mkdir usbmount;
mount /dev/usbdevice usbmount;
mkdir livedisc;
mount -o loop livedisc.iso livedisc;
rsync -avh livedisc/* usbmount/

Grub would then need to be installed on the device..

grub-install --no-floppy --root-directory=usbmount /dev/usbdevice

This usb should then be bootable. I cannot give help on how to enable persistence as this might be different on a per distro basis.

Hopefully this will get you started. Its the same basic idea behind a persistent backtrack usb.

Good luck.

share|improve this answer

In theory, yes. You could have a Live Ubuntu USB stick with VirtulBox-for-Linux installed inside. However the read/write speads would be appalingly slow and I don't know if it installs any extra drivers...but if it does so it would install them to the USB...

I'd say plausible, but not reccomended.

share|improve this answer
Considering the fact that XP is almost 10 years old when hardware was much slower, and that a good decent 16/32 GB flash drive can run at 30/40 or 50/60 (read write MBps) I will take the chance with speed. I asked the question because I also think it plausible, but any links, tuts etc? – RichardTheKiwi Apr 18 '11 at 21:47
you could use uNetBootin to screate a live USB stick, then boot from that and install VirtualBox and inside it. Then you'll need to install a Guest OS in a VM by following Good question though, I may try it myself and write up a tutorial. – tombull89 Apr 18 '11 at 21:53
I need to be 100% sure this works before deciding what my next USB flash drive is going to be (16/32/64 GB) or just a couple of slow 4 GBs if I won't be carrying bootable VMs with me. – RichardTheKiwi Apr 18 '11 at 21:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .