DEV Community

Toluwani Oluwaloseyi
Toluwani Oluwaloseyi

Posted on

How to create a virtual machine scales set with load balancer

Image description

Azure Virtual Machine Scale Sets let you create and manage a group of load balanced VMs. The number of VM instances can automatically increase or decrease in response to demand or a defined schedule.

Azure Load Balancer is a high-performance, ultra low-latency Layer 4 load-balancing service (inbound and outbound) for all UDP and TCP protocols. It is built to handle millions of requests per second while ensuring your solution is highly available.

Step 1:
Visit portal.azure.com, login or sign up if you don't have an account, you can get a free account at azure.microsoft.com/en-us/free/

Step 2:
Search for virtual machine scale sets aand click on "create"

Image description

Step 3:

  1. Subscription: Choose the subscription where you wish to create the resource.
  2. Resource group: Choose the resource group where you wish to create the resource. If you wish to create a new group click on create a new option.
  3. Virtual machine scale set name: Enter a preferred unique name.
  4. Region: Select the location where you wish to create the account.
  5. Image: Choose windows because we're creating a scale set windows VM.
  6. Username: azureuser
  7. Password: Password12345

Click on "review+create"

Image description

Image description

Step 4:
Go to "networking" to configure load balancer. Leave the virtual network as default that azure has chosen for us.
We're using a load balancer because if you're creating a scale set, that means you're having an additional VM to support what you already have to be able to distribute traffic to the VM.

Image description

Step 5:
Go to "health" and Enable application health monitoring, then click on "review and create"

Image description

Step 6:
Click on "create", then "go to resource"

Image description

Image description

Step 7:
Click on "instances" to know if your scale sets running

Image description

Step 8:
Click on scaling to either choose manual scaling(to mainatain a fixed instance count) or custom autoscale(if you want everything to be done automatically using certain number of conditions to choose a time range)

Image description

Thank you for reading...

Top comments (0)