# Configure Hyper-V

The following steps will add the necessary configuration to support development and test of Edge software. The starting point for these steps begin on the first login to the Windows Server. The primary goal is to configure the environment to support multiple Linux VMs that acquire DHCP addresses and have access to the WWW. Where the steps are not trivial, addition guidance is provided. Here is an over view of the steps covered in this article:

  • Update the timezone to match your local time and region
  • Verifify IE Enhanced Security is Off for Administrators. This will allow download of Chrome.
  • Install Chrome
  • Install Hyper-V, reboot
  • Create NAT network
  • Install and configure DHCP
  • Run Windows Update to install the latest Mircosoft Updates

The detailed steps are linked to below. Once completed, the node can be VNET peered to a Ability Instance. VNET peering will allow access to the Platform Instance APIs and this will allow uploading types and accessing any data sent to the Platform from Edge devices.

TIP

These install steps will also work with non-Azure Windows Server installations. However, Instance API access will not be possible if non-Azure hardware is used. The server can still be used to host Edge nodes but another machine will be needed to access Instance APIs.

TIP

Windows 10 creates a NAT and provides DHCP addresses to Virtual Machines when Hyper-V is installed. Windows 10 is an alternate enviroment that can be used. If the Windows 10 hardware meets the desired performance requirements, the Windows 10 environment could be used to provide the same environment this procedure is creating on Windows Server. See Hyper-V on Windows for more information.

# Prerequisites

# Set the Timezone

  1. Start the Server Manager

Server Manager

  1. Select Configure this local server

Server Manager

  1. Select the timezone link to pick the desired timezone.

Server Manager

# Confirm IE Enhanced Security Setting

  1. From the Server Manager application, again select Configure this local server and select the link for IE Enhanced Security Configuration

Server Manager

  1. Verify the setting are as follows. If not, modify to match and save.

Server Manager

  1. Using Internet Explorer, Install Chrome and set Chrome as the default browser.

# Install Hyper-V

  1. Start the Server Manager

Server Manager

  1. Select Add Roles and Features

Server Manager

  1. Follow these screens to install Hyper-V

Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager

  1. Reboot when installation is complete

# Create NAT

Virtual Machines on Azure VM require a local NAT network. This provides a network for DHCP to automatically provide network cofiguration and internet access for the virtual machines.

  1. Open a cmd prompt.
  2. Use Notepad.exe to create a nat.ps1 file, notepad.exe nat.ps1
  3. Copy the following into the file and save and exit note pad.
New-VMSwitch -Name VmNAT -SwitchType Internal
New-NetNat -Name LocalNAT -InternalIPInterfaceAddressPrefix "192.168.49.0/24"
Get-NetAdapter "vEthernet (VmNat)" | New-NetIPAddress -IPAddress 192.168.49.1 -AddressFamily IPv4 -PrefixLength 24
  1. Execute the file. ./nat.ps1
  2. Open Hyper-V Manager and confirm the VmNat virtual swtich is defined.

Server Manager Server Manager

# DHCP

Windows server provides DHCP functionality. The following steps will install and configure it to support the NAT created.

  1. Start the Server Manager

Server Manager

  1. Select Add Roles and Features

Server Manager

  1. Select 'DHCP`

Server Manager

  1. Select Next for the remaining srceens until the install screen

Server Manager

  1. Once the install is complete, return to the Server manager to complete the DHCP configuration.

Server Manager Server Manager Server Manager

# Configure DHCP

DHCP can be configured for the VmNAT previously created. This will provide automatic IP addresses for all the VMs created on the VmNAT virtual switch. All VMs will have internet access with this configuratoin.

  1. From the Server Manager, open the DHCP Administorator tool.

Server Manager

  1. Select IPv4 and Create Scope from the pull down menu.

Server Manager

  1. Follow these steps to create the DHCP Scope

Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager Server Manager

# Run Windows Update

Open the setting and navigate to Windows Updates. Check for and install the latest updates.

# Install Putty

The Hyper-V console if very limiting when using cut/paste to transfer information. When using Putty, the window provides a scroll bar to review output and it is easy to cut and paste text from the host to/from the Putty window. Other terminal applications can be used if Putty doesn't meet your needs.

# Install WinSCP

WinSCP can be used to transfer files to and from Ubuntu VMs.

TIP

If you configure all you logins with Putty before you start WinSCP the first time, WinSCP will prompt you to import all the Putty sessions into WinSCP.

# Next Steps

The server is now configured and will support creation of new Hyper V Virtual machines. DHCP will automatically provide an address for each machine. Continue to follow the Advanced Edge Development and Testing learning path to create a development Linux VM that can run client applications to communicate with the platform, build customer edges modules, and test them.

Last updated: 7/20/2021, 8:42:12 AM
Feedback