Exercise: Resolve issue connecting virtual machine scale set

Completed

After investigating the connection issues to your website, you've found an issue with the load balancer rule user by the virtual machine scale set.

In this exercise, you'll resolve the issue and check that the website can now be accessed.

Validate load balancer rules

  1. In the Azure portal, search for load balancers, and then under Services, select Load balancers.

    A screenshot showing searching for load balancers.

  2. Select the webLoadBalancer load balancer.

  3. Under Settings, select Load balancing rules.

    A screenshot showing the load balancer rule highlighted.

  4. From the list of rules, select webLoadBalancerRule.

    A screenshot of the load balancer rule, showing the port set to 80 and backend port set to 443. This is the error.

  5. To resolve the backend issue, change the Backend port from 443 to 80, and then select Save.

    Note

    The front and backend in this environment need to be the same to get a response from the webserver to http requests.

  6. Wait until the rule has been deployed successfully.

A screenshot showing the successful deployment of the updated load balancer rule.

Verify that the website can now be reached

  1. Refresh the tab you opened to test the public IP address.

    Note

    If you have closed the previous browser tab, run this command to get the public IP address:

    az network public-ip show \
    --resource-group <rgn>[sandbox resource group name]</rgn> \
    --name webPublicIP \
    --query '[ipAddress]' \
    --output tsv
    

    If the website is online, you'll see a page with a Hello World message from the backend instance.

A screenshot of the website showing it's online.