Booting Hyper-V R2 off a USB stick
A while ago we announced that Microsoft Hyper-V Server R2 would support booting off of a USB flash device. We have now provided detailed documentation on how to set this up. Even cooler than booting Hyper-V off of a USB device – is the fact that what we are doing is booting a VHD with Hyper-V installed on it off of a USB device:
If you are like me – you will probably think: “Cool! I have to check that out!” And then after looking over that page you will think: “Eh, that seems like a lot of work…”
Thankfully Paul Despe has made a little tool that makes this dead simple. You can grab it from here:
With this tool all you have to do is:
- Install the Windows Automated Installation Kit (WAIK)
- Grab Microsoft Hyper-V Server 2008 R2 and either burn it to a DVD or mount it with a virtual CD program
- Connect your USB flash device
- Run the tool As Administrator
- Select your USB flash device as your target disk
- Warning! You can select any disk in your system – and it will get formatted. Make sure you are selecting your USB flash disk – and you do not have any data on the disk that you want to keep.
- Click on the Create Blank VHD button and choose a temporary location for the VHD
- Locate your copy of the INSTALL.WIM file from the Microsoft Hyper-V Server 2008 R2
- Hit the Start button and wait a short time (~30 minutes on my system) for everything to be setup
When it is finished you can now take your USB flash disk and boot a system off of it. Once you have completed the standard Hyper-V Server post installation configuration – you can connect to the system remotely and start partying with Hyper-V.
You may be wondering why we are letting you do this. Well that is captured at the top of the TechNet article, to quote:
… The scenario described in this document is only supported for original equipment manufacturers (OEM) …
… A Hyper-V Server UFD can provide virtualization capability for servers that ship with no local hard disks, and it offers the same functionality and flexibility as a Hyper-V Server installation on a physical hard-drive …
The idea here is that OEMs / System Builders that want to make diskless Hyper-V servers (where the virtual machines are stored on some form of central storage) can do so by sticking some cheap flash storage on the disk.
Myself, I just like the idea of having a Hyper-V server with me ready to go at anytime
Some notes to be aware of include:
- This is only supported for Microsoft Hyper-V Server 2008 R2. Not for Windows Server 2008 R2.
- It is recommended that your USB flash disk be at least 8GB in size, and that you only fill your disk up to 75% to get the best performance / life span.
- For this reason Paul's tool defaults to creating a 6000MB virtual hard disk. You can change the size of the virtual hard disk using the File menu.
- While you can move the USB device from system to system and *most* things will work:
- This is not supported (if you read the whole TechNet article you will see that this is only supported if you are using a USB device that is hard-wired to the system).
- The virtual network switches will get disconnected whenever you move to a new system.
- To reduce wear-and-tear on your flash device, the page file is disabled by this tool. This means that you should not try and allocate every last megabyte in the system to virtual machines. Try to leave some room for processes in the parent partition.
As a final note – I did not have an 8GB flash device handy for testing this out – so I actually set this up using my PlayStation Portable (PSP). And it works! Now I just have to figure out how to keep Hyper-V on my PSP and still use it for playing games.