- Overview
- The Problem: how to set up a SharePoint farm on your laptop
- The Solution: Hyper-V and Nested Virtualization
- Steps in Brief
- Detailed Steps
Overview
The combination of Windows 10 and Windows Server 2016 enable you to create a test lab on your local PC or laptop! This is because most versions of Windows 10 have the Hyper-V feature available. And Windows Server 2016 has a new feature called Nested Virtualization. So you can easily create a virtual test lab consisting of one virtual machine hosting several other virtual machines!

Recently, I needed to create a SharePoint farm on my laptop. This SharePoint farm would become my pseudo “Production” environment that I will then replicate to the cloud using Azure Site Recovery (ASR). So Windows 10 and Windows Server 2016 were the perfect tools for the job.
Note: The solution presented in this post can be used to create any test lab (sandbox environment) – not just a SharePoint farm.
The Problem – how to set up a SharePoint farm on a laptop?
As mentioned earlier, I will be using Azure Site Recovery (ASR) to replicate my local SharePoint farm to the Cloud. This means that I need nested virtualization. I cannot use Windows 10 Hyper-V to create the three SharePoint VM’s because Windows 10 is not supported as an ASR host. So I have to install a host server VM (Windows Server 2012 R2 or Windows Server 2016) on Windows 10 Hyper-V. And subsequently, on this host server, I have to install the three SharePoint server VM’s.
Furthermore, having the SharePoint Farm VM’s hosted on Windows 10 does not represent a real production environment. The chosen architecture – 3 SP Farm VM’s hosted on Windows Server 2016 host – is more realistic and represents the architecture of a real Production SharePoint farm.
The Solution – Hyper-V and Nested Virtualization:
In order to create a SharePoint farm with 3 servers: a DC, a Sql Server, and a SharePoint server, you either need 3 physical servers or 3 virtual machines. At home, I do not have 3 physical servers. VM’s are the only way to go.
Windows Server 2016 has a wonderful new feature called Nested Virtualization!! Nested Virtualization is great for test scenarios and allows such a test lab to be created. In previous Windows Server versions you could not nest a Hyper-V environment inside another Hyper-V environment. Or at least, the nesting was was not supported by Microsoft.
And certain versions of Windows 10 have the Hyper-V feature readily available. You just need to turn it ON. This allows you to create the Windows Server 2016 host Virtual Machine (VM) without installing any new software or applications.
Setting Up the SharePoint Farm – In Brief
- Check the software and hardware requirements on your laptop or desktop PC
- Turn Hyper-V feature ON in Windows 10
- Create a new VM and install Windows Server 2016 on it. Enable Nested Virtualization for this VM.
- Set up networking for your SharePoint farm. We will use a separate subnet for each SharePoint VM and we will link them up with RRAS. You do not have to use this many subnets. You can use one subnet for all your VM’s. I chose to use 3 subnets because I wanted my environment to mimic a VNet in Azure.
- Install the 3 SharePoint VM’s: DC, Sql Server 2016, SharePoint 2016
Setting up the SharePoint Farm – Detailed Steps:
1. Check Windows 10 Hyper-V requirements:
Software requirements:
The following Windows 10 versions support Hyper-V virtualization: Enterprise, Professional and Education.
Hardware requirements:
Hyper-V normally requires at least 4GB memory. However, for this SharePoint farm (1 host VM and 3 guest VM’s), at least 10 GB of RAM would be needed. I recommend 16 GB of RAM. With 16GB on your laptop or PC, you will have about 10 GB RAM left for the SharePoint farm. I assigned 1GB RAM for the DC VM and 2GB RAM each for SharePoint VM and Sql Server VM.
Remember that Windows 10 OS uses about 2 GB and there is something called the host reserve which takes about 2.5GB (depending on how much physical RAM exists on the machine).
Other hardware requirements:
- 64-bit Processor with Second Level Address Translation (SLAT).
- CPU support for VM Monitor Mode Extension (VT-c on Intel CPU’s).
A good way to check on all the system requirements for Hyper-V is to run the command line utility systeminfo.exe. Open a Command Prompt window and type systeminfo.exe. The output of the command will contain a section on Hyper-V Requirements. Make sure all tests return a “Yes”.
2. Turn Hyper-V Feature ON in Windows 10
In the Control Panel, start Programs and Features and click on “Turn Windows Features On or Off”. Select the Hyper-V checkbox. This includes “Hyper-V” platform and “Hyper-V Management Tools”. Finally, perform a restart.
3. Create a new Windows Server 2016 VM and Enable Nested Virtualization.
1. Install Windows Server 2016 on this VM. This Windows Server 2016 VM will host your SharePoint farm.
2. With the Windows Server 2016 VM OFF – in Windows 10 – run the following Powershell commands:
Set-VMProcessor -VMName <VMName> -ExposeVirtualizationExtensions $true Get-VMNetworkAdapter -VMName <VMName> | Set-VMNetworkAdapter -MacAddressSpoofing On
3. Under the VM settings for the Windows Server 2016 VM, turn OFF Dynamic memory for the VM
4. Give the VM enough memory. I assigned 10 GB to the VM.
4. Set up networking for your SharePoint farm
I wanted the network of my lab to resemble a real Production environment and to mimic the virtual network (VNet) that is used in Azure. So I configured Hyper-V for multiple subnets while using only one NIC.
On the Windows Server 2016 host:
-
-
- Create 4 Virtual Switches. One external and 3 internal.
I chose: 10.0.0.1/24 for the DC VM, 10.0.1.0/24 for Sql Server and 10.0.2.0/24 for the SharePoint VM. - Configure the network adapters on the Hyper-V host
- Configure Routing and Remote Access Service (RRAS) on the host. RRAS acts as a software router and connects the subnets.
- In Server Manager, click on Manage – Add Roles and Features
- The first page is informational and may be skipped
- On the second page: choose Role-based or Feature-based installation
- Choose the server (local server) where the RRAS feature will be added
- Select Remote Access on the Roles page
- Under the Features page:
- select RAS Connection Manager Administration Kit (CMAK)
- under Remote Server Admin Tools – Role Admin Tools: select Remote Access Management Tools
- On the Role Services page, select “DirectAccess and VPN (RAS)” and select Routing
- You will be prompted to add features required by DirectAccess and VPN (RAS)”, click YES.
- Make sure Routing is still selected
- Review the information on the Web Server Role (IIS) page
- Click Next on the Roles Services page
- Do a final confirmation and Install
- When it is done, Close the wizard
- Open the Routing and Remote Access application
- Right click on your server name and select “Configure and Enable Routing and Remote Access”
- Select Custom Configuration
- Select NAT and LAN Routing. NAT allows your VM’s Intern
- Create 4 Virtual Switches. One external and 3 internal.
-
5. Create 3 new VM’s inside the Hyper-V Host
-
- Install the Domain Controller (DC). You can use Desired State Configuration (DSC) to set up the ADDS Domain Controller automatically by using a script. You can see the steps in my blog post on the subject.
- Install the Sql Server 2016 and
- SharePoint Server 2016