Virtualization is a critical part of modern IT infrastructure that presents many routine management tasks to system administrators, including increasing virtual hard disk space when needed. In my job, due to expanding log files, scaling growing processes, and new tasks for existing servers, this is something I do at least once a month.
Here’s how to do it in a Microsoft Server Hyper-V hypervisor running Windows Server 2016 using Hyper-V Manager or Failover Cluster Manager.
Hyper-V is a Type 1 hypervisor that is installed directly on the underlying hardware and acts as a lightweight operating system on which virtual machines are created. By being installed directly on the hardware, the performance of the VM is better than with a type 2 hypervisor which has an operating system intermediate between itself and the hardware.
The two main management tools for Hyper-V that can be used to increase virtual hard disk space are Hyper-V Manager and Failover Cluster Manager. Failover Cluster Manager is only used if multiple VM hosts are running and the hosts are clustered, allowing disaster recovery if a physical machine goes down. It also avoids downtime when performing updates on host machines. (While clustering is a useful tactic, it doesn’t replace the need for regular backups of everything.)
Hyper-V Manager is used to increase disk space if you only have one physical host or if you have multiple hosts that are not clustered.
The following steps show how to increase space using Hyper-V Manager and Failover Cluster Manager. They start with Hyper-V Manager.
First, shut down the virtual machine where you are going to increase the disk space. To verify that it is stopped, verify that the entry in the State column for the VM reads “Off.” Then click to open Settings from the menu on the right side of the screen.
If you are using Failover Cluster Manager, select the role (another name for a virtual machine) you are working on, then click to open Settings from the menu on the right side of the screen.
This next part is the same whether you are in Hyper-V Manager or Failover Cluster Manager.
From the left menu, select the hard drive you want to expand. Most likely this will be a simulated Integrated Drive Electronics (IDE) controller, but it could instead be an Internet Small Computer Systems Interface (iSCSI) controller, depending on what you chose during setup. of the reader. Click Edit under Virtual Hard Disk Path in the Media section of the dialog box.
Check that the location of the drive is correct. Click on Next.
On the Choose Action screen, select Expand from the options. Click on Next.
On the Configure Disk screen, you need to enter the size in GB that you want the hard drive to be after the expansion. Click on Next.
Finally, review the summary to make sure everything is correct, and if so, click Finish.
Back in Hyper-V Manager or Failover Cluster Manager, select the virtual machine you are working with, then click Start to wake it up. In both management tools, the Start button is on the right menu at the location of the Settings button. Here’s what it looks like in Hyper-V Manager:
And here it is in Failover Cluster Manager:
Using Windows Server 2016, open Server Manager and navigate to Tools in the upper right corner, then click Computer Management from the drop-down menu.
Under Computer Management in the left menu, click Navigate to Disk Management.
In the lower half of the dialog box is a section that shows the unallocated share of your hard drive partition. (In the image below, this unallocated space is partially blocked by the drop-down menu.) Right-click the hard drive partition and select Extend Volume.
The Extend Volume Wizard dialog box appears. Click on Next.
On the next screen, all unallocated space will automatically be added to the Selected side of the space selection box. Make sure the amount of space added is correct. Click on Next.
Click “Finish” to complete the extension.
Then you should see your hard drive extended with the new space reflected.
Adding space to virtual hard disks is a simple task which is another benefit of having virtual machines.
Copyright © 2021 IDG Communications, Inc.