Hello,
Have you ever want to try to install a “Scale-Out File Server” or any kind of guest clustering in your home lab ?
If you’re like me, you just have one computer, with some VM’s on it, but no shared storage nor multiple physical computers available for a Hyper-V. That’s not an end, you can build a virtual cluster without any physical shared storage, here’s how :
You have two solutions to present virtual shared storage to your VM’s :
- Use the iSCSI Windows Feature (Separate download for 2008R2, integrated since 2012).
- Use shared VHDX (Hyper-V 2012R2).
Today, we’ll focus on the shared VHDX solution. The following is completely UNSUPPORTED by Microsoft, we do it for testing/learning purpose ONLY.
- On the Hyper-V host, install the fail over clustering feature (Install-WindowsFeature failover-clustering).
- Execute that command “fltmc.exe attach svhdxflt E:” with E: being the drive that will contain the shared VHDX.
- Make a new VHDX on the drive (New-VHD -Path “e:Shared.vhdx” -SizeBytes 500GB -Dynamic).
- Attach that VHDX to your VM’s (Add-VMHardDiskDrive -ControllerType SCSI -Path “e:Shared.vhdx” -VMName $vm -ControllerNumber 0 -SupportPersistentReservations -ControllerLocation 1).
- Now, your VHDX is available from the VM’s, you can add it to the cluster (Add-ClusterDisk).
PS : You need to run the FLTMC command at each host’s boot, it isn’t persistent.