Windows Server 2019 – Designing and implementing your Hyper-V Server

How to turn off IE enhanced security on Windows Server 2019

Creating your own Hyper-V Server is usually pretty simple: build a server, install the Hyper-V role, and you’re ready to get started. In fact, you can even install the Hyper-V role onto a Windows 10 Pro or Enterprise computer, if you need to run some virtual machines from your own desktop. While most hardware that is being created these days fully supports the idea of being a hypervisor provider, some of you may try installing the Hyper-V role only to end up with the following error message:

Uh oh, that’s not good. This means one of two things: either my CPU really doesn’t support virtualization, or I simply have some settings turned off inside the BIOS on my server that are preventing this from working. There are three considerations you should check into on your server to make sure it is ready to run Hyper-V. First, you need to be running an x64-based processor. This is kind of a given, since Windows Server 2019 only comes in 64 bit anyway. If you don’t have an x64 processor, you’re not going to be able to install the operating system in the first place. Second, your CPUs need to be capable of hardware-assisted virtualization. This is typically called either Intel Virtualization Technology (Intel VT) or AMD Virtualization (AMD-V). And last but not least, you must have Data Execution Prevention (DEP) available and enabled on your system. If you have investigated the hardware itself and it seems to be virtualization-capable, but it’s still not working, it is likely that you have DEP currently disabled inside the BIOS of that system. Boot into the BIOS settings and enable DEP, along with any other more-user-friendly-named settings that might indicate they are currently blocking your ability to run virtual machines.

As long as your processors are happy to run virtual machines, you can turn just about any size of hardware into a hypervisor by installing the Hyper-V role. It is not important to think about minimum system requirements because you want your system hardware to be as large as possible in a Hyper-V Server. The more CPU cores, RAM, and hard drive space you can provide, the more VMs you will be able to run. Even the smallest Hyper-V Servers I have seen in production environments are running hardware such as dual Xeon processors, 96 GB of RAM, and many terabytes of storage space. While 96 GB of RAM may seem like a lot for a single system, if your standard workload server build includes 8 GB of RAM, which is a pretty low number, and you want to run 12 servers on your Hyper-V Server, you are already beyond the capabilities of a Hyper-V Server with only 96 GB of RAM. 8 times 12 is 96, and you haven’t left any memory for the host operating system to use! So the moral of the story? Go big or go home!

Installing the Hyper-V role

Hyper-V is just another role in Windows Server 2019, but during the installation of that role, you will be asked a few questions and it is important to understand what they are asking, so that you can be sure your new Hyper-V Server is built to last and to work in an efficient manner. First of all, you will need to have Windows Server 2019 already installed, and use the Add roles and features function in order to install the role called Hyper-V:

As you continue working through the wizard to install the role, you come across a screen labeled Create Virtual Switches. We will discuss networking in Hyper-V a little bit more in the next section of this chapter, but what is important here is that you get to define which of your server’s physical NICs will be tied into Hyper-V, and available for your virtual machines to use. It is a good idea for each Hyper-V Server to have multiple NICs. You want one NIC dedicated to the host itself, which you would not select in this screen. Leave that one alone for the hypervisor’s own communications. In addition to that NIC, you will want at least one network card that can bridge the VMs into the corporate network. This one you would select, as you can see in the upcoming screenshot. If you will be hosting many different VMs on this server, and they need to be connected to different physical networks, you might have to install many different NICs onto your Hyper-V Server:

After defining NICs, we get to decide whether this Hyper-V Server will be able to handle the live migration of VMs. Live VM migration is the ability to move a VM from one Hyper-V host to another, without any interruption of service on that VM. As you can see in the following screenshot, there are a couple of different ways you can set up the server to prepare it for handling live migrations, and take note of the text at the bottom that is telling you to leave this option alone for now if you plan to make this Hyper-V Server part of a cluster. In clustered environments, these settings are handled at a different layer:

The last screen that I wanted to point out is the definition of storage locations for your VM data. After creating VMs and digging into what they look like at the hard-disk level (looking at the actual files that are created per-VM), you will see that there are two key aspects to a VM: the virtual hard disk file, Virtual Hard Disk (VHD) or VHDX, and a folder that contains the configuration files for that VM.

As you can see in the upcoming screenshot, the default locations for storing these items are something you would expect out of a client application you were installing onto a laptop, but you wouldn’t expect something as heavy as Hyper-V to be storing its core files into a shared-user Documents folder. I suppose since Microsoft doesn’t know the configuration of your server, it can’t make any real guesses as to where you want to really store that data, and so it sets the default to be something that would work technically, but should probably be changed as a matter of best practice. Many Hyper-V Servers will have dedicated storage, even if only a separate hard disk, on which these files are planned to be stored. Make sure you take a minute on this screen and change the default storage locations of your VM files:

Remember that the version of Windows Server 2019 you are running determines how many VMs you will be able to run on top of this host. Server 2019 Standard limits you to running two VMs, while Datacenter edition gives you access to launch as many as you can fit on the hardware.

Comments are closed.