Hyper-V Role Installation, Remote Management, and Storage Configuration

Previously, we walked through getting the Windows Server 2016 operating system (OS) installed as a Server Core installation, as well as the initial configuration of the server. Now, let’s take a look at installing the Hyper-V role onto the new Server Core OS.

Now that you have changed the computer name, joined a domain, and rebooted the server, you can install the Hyper-V role. You can do this by running a command from PowerShell. At the command prompt, type powershell to launch PowerShell, then type the following command:

Install-WindowsFeature-Name Hyper-V-Restart

Administration of Server Core

Because are no management utilities built into the Server Core, for administration, you must use an administrative workstation or server. Alternatively, you can connect using Hyper-V management tools or other Microsoft Management Consoles.

If you are using a workstation OS such as Windows 10 for administration, you must download the Remote Server Administration Tools (RSAT) if you want to use the Hyper-V management tools. Windows Server 2016 OS environments already have the binaries installed for Remote Administration Tools, however, the Hyper-V Management Tools need to be activated in the Server Manager under Features. Various firewall rules may need to be enabled on the Hyper-V server before connectivity from the management workstation or server is allowed. Hyper-V backup

Hyper-V Role: Storage Configuration

If you have additional dedicated storage that you would like to bring online for VM storage, this can be accomplished with the diskpart utility. I provisioned a 1TB hard drive in the lab host for this example. Using the diskpart commands below, bring the disk online, perform conversion to a GPT (GUID Partition Table) disk, create a partition, and format the file system.

DISKPART> list disk DISKPART> select disk 〈disk number〉 DISKPART> online disk DISKPART> attributes disk clear readonly DISKPART> clean DISKPART> convert gpt DISKPART> create partition primary DISKPART> select volume 〈volume number〉 DISKPART> format fs=refs label=VMs quick DISKPART> assign letter d DISKPART> list volume

If you want to use Disk Management for remote administration of the Core Installation of Hyper-V Server, you must add a firewall exception. Use the following command:

Netsh advfirewall firewall set rule group=”Remote Volume Management” new enable=yes

*Note The Windows firewall might be running on the client from which you are trying to connect with the disk management MMC console. If this is the case, the command above must be run on both the Server side and the client.

Hyper-V Settings

Once you have your storage purposed for VM storage online, you can modify the Hyper-V Settings on the server. To do this, open the virtmgmt.msc console on either your Windows management workstation or the Server OS. This launches the Hyper-V Manager.

From here, you can configure your Hyper-V Settings and Virtual Switches. First, change the default location for your Virtual Hard Disks and configuration files, from the default location on the system drive to your dedicated storage. This best practice improves performance a facilitates administration. In the example below, I have changed the Virtual Hard Disk as well as the Virtual Machine configuration location to the new volume mounted as D:\ in Windows. Now the VMs are located on the dedicated storage for virtual machines.

From a storage point of view, on the standalone host, I have storage mounted and configured. Hyper-V is utilizing the new location for storing the virtual hard disks and configuration files.

This blog post is the fourth in a series on how to use Microsoft’s Windows Server 2016 and Hyper-V for virtualization. We start with the basics, then progress to more advanced tasks and functionalities. Next, we show you how to configure Hyper-V host networking and virtual switches.

At NAKIVO, we understand Hyper-V. Our team of experts built NAKIVO Backup & Replication’s functionality while taking all the nuances of Microsoft’s hypervisor into account. This is why you get seamless, efficient, and reliable Hyper-V backup with our solution.

Try for yourself in your own (newly created) Hyper-V environment: download the full-featured free trial.

Article originally published on the NAKIVO website