Save to My DOJO
Creating a new Hyper-V in Hyper-V from scratch is a straightforward process using Hyper-V Manager. For the sake of simplicity, most of the possible configuration options are not available during initial creation. The wizard does present a number of options that may not be entirely obvious for those not experienced with its nuances.
To create a new virtual machine, open Hyper-V Manager and follow these steps:
- In the left pane, click on the Hyper-V host that you wish to host the new virtual machine.
- In the right-hand Actions pane, click New, then Virtual Machine to start the wizard.
- The first page of the New Virtual Machine Wizard is purely informational. Click Next when ready.
- The first data screen asks for the name of the virtual machine and the initial location. The name that you choose will be used as a label in all virtual machine tools, including Hyper-V Manager, Failover Cluster Manager, and PowerShell. The name of the guest operating system that you’ll eventually install will not be automatically set to this, and does not need to be the same.
If you do not check the option to Store the virtual machine in a different location, then all of the virtual machine’s metadata (XML, BIN, VSV, and second-level paging files) will all be placed in the host’s default location. This path will be visible in the grayed out text box. Checking the box allows you to override this location. If it’s never held a virtual machine before, a subfolder named “Virtual Machines” will be created in the path that you specified. Whether that folder is new or existing, another subfolder will be created underneath it that will have the name of the automatically-generated GUID that represents the virtual machine. Security will automatically be configured for you.
- On the next screen (2012 and later), you’ll be asked to choose the Generation of the virtual machine. Generation 1 operates in the traditional BIOS mode and will be compatible will virtually any guest operating system. It allows the use of “legacy” hardware like the emulated virtual network adapter and IDE hard disks. Generation 2 virtual machines use the newer UEFI standard and is only compatible with newer guest operating systems, like Windows Server 2012, Windows 8, and recent Linux distributions. It opens up a number of features that you can read about in this TechNet article.
- On the next screen, you set the preliminary memory settings for the virtual machine. You only have two options: the amount of Startup memory and whether or not you wish to Use Dynamic Memory for this virtual machine. If you do not wish to use Dynamic Memory, leave the box unchecked and set the startup memory to the amount of memory that you wish the virtual machine to have. If you do wish to use Dynamic Memory, you’ll have to configure the minimums and maximums later. They will be automatically set to 512 and 1TB, respectively. Be aware that Windows Server 2012 and R2 will not install if the Startup memory is less than 1 gigabyte and the error message indicates an invalid license key, not insufficient memory.
- Next, you’ll need to determine how to connect the virtual network adapter. You can leave it at Not Connected, which means the virtual machine will begin its life without any network connectivity. Otherwise, you can connect it to a virtual switch right away. Be aware that you can’t set any advanced options such as the VLAN here. Whatever you choose, this adapter is always the newer synthetic adapter, which cannot be used to PXE boot a Generation 1 virtual machine. If you need that functionality, it is granted on a later screen.
- After networking, you’ll be asked to configure the first virtual hard disk for the virtual machine. You have three options on this screen. The first is to build a new virtual hard disk file. It will always be dynamically expanding and, in 2012+, will always be VHDX (as opposed to the earlier VHD). Unlike the virtual machine placement, the destination location specified on this screen will be the exact placement of the generated VHDX file.
The second option allows you to connect an existing virtual hard disk. It cannot be currently in use. If it is attached to another virtual machine that is currently turned off, security will be reset for this virtual machine. You cannot use this wizard to establish one of the new shared virtual hard disks; such a virtual hard disks cannot be the boot disk of a virtual machine.
The final option is to not connect a virtual hard disk at all.
You cannot use this wizard to connect to a physical hard disk (pass-through). Contrary to a myth that’s circulating, you can, in fact, use a physical disk as the primary disk for a Hyper-V virtual machine in recent versions. That doesn’t change the fact that you should just stop using physical hard disks altogether.
- The Installation Options tab is indented in the left-hand navigation pane of the wizard for good reason: it will only appear if you chose to create a new virtual hard disk.
The first option, Install an operating system later, creates the virtual machine with all of the previous settings and then does nothing else.
The second option, Install an operating system from a bootable CD/DVD-ROM, allows you to select an ISO image or, for a Generation 1 VM, connect the host’s physical optical drive directly to the virtual machine. If you select this option, the image or disc will be “inserted” into the virtual machine’s virtual optical drive and the virtual machine will be set to boot from it.
The option to use a virtual floppy disk is only available on Generation 1 virtual machines, as the Generation 2 virtual machine does not allow virtual floppies. Even for Generation 1 machines, this is an extremely rare circumstance. You can easily create a virtual floppy image using Hyper-V Manager, but you will need a functioning virtual machine to work with it.
The final option sets the virtual machine to boot from a virtual network adapter (PXE boot). If you have created a Generation 1 virtual machine, this will cause a legacy virtual NIC to be created. In the following screenshot, note that the option is grayed out. This will happen if no virtual switch was selected for the primary network adapter. If you have created a Generation 2 virtual machine, no extra NIC is created.
- The final screen is simply a confirmation and your last opportunity to go back and make any necessary changes.
Once you click Finish, the wizard undertakes all of the options that you selected and creates the virtual machine. The wizard does not turn the virtual machine on, so you have an opportunity to make any desired modifications beforehand.
One important thing to take note of is that there is no screen allowing you to select the number of virtual CPUs. All virtual machines are always created with only one.
Not a DOJO Member yet?
Join thousands of other IT pros and receive a weekly roundup email with the latest content & updates!