To test the VMs properly, we are going to install Internet Information Services (IIS) on the PacktLBVM1 and PacktLBVM2 VMs using PowerShell. Then, we can use the PacktLBVMTest VM to test the load balancer by calling its private IP address.
First, we need to obtain the private IP address of the load balancer. Take the following steps:
- In the Overview page of the load balancer, copy the private IP address as follows:
Obtaining the private IP address
- Now, we need to connect to the PacktLBVM1 and PacktLBVM2 VM using an RDP session and install IIS and a testing web page on it. Connect to both the VMs, open the PowerShell console, and provide the following PowerShell script:
# Install IIS
Install-WindowsFeature -name Web-Server -IncludeManagementTools
# Remove default htm file
remove-item C:\inetpub\wwwroot\iisstart.htm
#Add custom htm file
Add-Content...