How to install Windows Server 2016 VM on a Hyper-V Windows 10 Device GUI and PowerShell

No comments

How to Create/Install Windows Server 2016 VM on your Hyper-V Windows 10 Device (Surface Pro 4)

As you might know Hyper-V role/feature is included on Windows 7,8, 8.1 and 10. This allows you to create your own test environments and also you pre-production development systems. So you can test new features and so on.

How to install the role on my Windows 10 ?

To install the role/feature is pretty straight forward just make sure you perform the following tasks;
1. Go to your BIOS and make sure the Hypervisor /Virtualization Technology is enabled.
2. After enabling your Hypervisor, search on Turn Windows Features on or off and enable all the Hyper-V features.
3. After enabling the role, restart your computer and open the Hyper-V manager Console.
4. That's it, now you have Hyper-V Role installed on your Windows 10 Device.

Creating and Installing the 2016 VM Step by Step

1. Open the Hyper-V Manager, click New then create a new Virtual machine.
2. On the Virtual Machine Wizard specify he following: Name, Path, Generation, RAM, Network, VHD and the ISO to install the OS in my case Windows Server 2016.
3. Once the VM is created then start the VM and press any key to install the OS from the attached ISO then follow all the OS installation wizard.
4. Now you have your new VM installed on your Windows 10 device.


You can also create the VM utilizing PowerShell

1. Go to your PowerShell ISE as Admin then run the following pscript.

# Make sure you change the VM Name, Switch Name, and Installation Media Path.
$VMName = 'Server2016'
$Switch = 'Private NIC Teaming Switch'
$InstallMedia = 'C:\Temp\Server2016.iso'
# Create New Virtual Machine
New-VM -Name $VMName -MemoryStartupBytes 2147483648 -Generation 2 -NewVHDPath "C:\Virtual Machines\$VMName\$VMName.vhdx" -NewVHDSizeBytes 53687091200 -Path "C:\Virtual Machines\$VMName" -SwitchName $Switch
# Add DVD Drive to Virtual Machine
Add-VMScsiController -VMName $VMName
Add-VMDvdDrive -VMName $VMName -ControllerNumber 1 -ControllerLocation 0 -Path $InstallMedia
# Mount Installation Media
$DVDDrive = Get-VMDvdDrive -VMName $VMName
# Configure Virtual Machine to Boot from DVD
Set-VMFirmware -VMName $VMName -FirstBootDevice $DVDDrive
Thanks for watching! :)

No comments :

Post a Comment