Managing Virtual Hard Disks (VHDs) is an advanced storage option that you should know for being an IT professional. This option allows you to create and mount VHDs in the similar way as you use a physical drive. One of the major advantages of using VHDs is that they can be moved easily from one machine to another machine. In addition, you can easily mount VHDs by just double-clicking on it. In this post, we will explain the basics of VHDs and how to create and mount VHDs in Window machines.
Also read: Managing disks in Windows
VHD vs VHDX
A VHD file can be in either of the following formats:
- Uses a 512-byte block size internally.
- Is limited to a 2TB.
- Does not support live resizing (cannot be resized while being used).
- Supports live resizing of virtual disks.
- Uses 4KB block size.
- Handles power failure conditions in better manner.
- Handles snapshots in the better manner.
- Supports up to 64 TB of a disk size.
Fixed vs Dynamic VHDs
While creating a VHD, you can select either of the following VHD types:
- Fixed size: A virtual hard disk file is allocated to its maximum size when the virtual hard disk is created.
- Dynamically expanding: The virtual hard file grows to its maximum size as data is written to virtual hard disk. Only supported on Windows 8, Windows Server 2012, and later.
Creating a VHD File
To create a VHD in the latest version of Windows operating systems such as Window 8/10, you need to perform the following steps:
- In the Disk Management window, navigate to Action> Create VHD.
- On the Create and Attach Virtual Hard Disks dialog box, click Browse. In the File name text box, type a name of VHD such as VHD1 and then click Save.
- In the Virtual hard disk size box, set the VHD size, format, and type, and then click OK.
- Virtual disk size: 10 GB
- Virtual disk format: VHD
- Virtual hard disk file: Dynamically expanding
- On the Disk Management window, select and right-click the added disk (Disk 1), and then select Initialize Disk. Select either MBR or GPT partition table and then click OK.
- Now, select and right-click Unallocated space of Disk 1, and then select New Simple Volume.
- Complete the New Simple Volume Wizard using your desired options or jus accept the default selections. Use the created volume as you use a volume created on a physical drive.
Detaching a VHD File
If you do not want to use a VHD file, you can detach or unmount it. To do so, you need to perform the following steps:
- Select and right-click the VHD that you want to detach and select Detach VHD.
- On the Detach Virtual Hard Disk message box, click OK and close the Disk Management window.
- If you decide to reuse or remount the created VHD, navigate to its location and double-click to mount it.
In this post, we have explained how to create, mount, use, and detach VHDs in Windows machines. Please drop your queries in the comment box, if you want something to suggest or say to us. You may also share the article to encourage us.