In this article, I will explore how to create virtual machine scale set in Azure. A virtual machine scale set permits you to deploy and manage a set of identical, auto scaling VM. We can scale the number of virtual machines in the scale-set manually, or specific rules to auto-scale based on resource usages like memory demand, CPU, or network traffic. An Azure load balancer then distributes traffic to the VM instances in the scale set.
Create a Load Balancer
Azure load balancer disseminates incoming traffic among healthy VM instances.
Create a public Standard Load Balancer by using the Azure portal. The public IP address and name we create are automatically configured as the load balancer’s front end.
1- In the Azure search box, type load balancer and then pick Load balancer.
2- Select + Add
3- Create load balancer wizard, In the Basics tab,
Select Subscription – Select your subscription
Resource group – select your resource group (mg-rg)
4- Instance details
Name – type a unique name (myloadbalancer)
Region – select a region (Central US)
Type – Select Public
SKU – Select Standard
5- Public IP address
Select create new
Public IP address name – Enter a name (mypublicip)
Availability zone – select Zone-redundant
Select Review + create
6- After it passes validation, select Create.
7- Load balancer successfully created.
create virtual machine scale set in Azure
We can deploy a scale set with a Linux or Windows Server images such as RHEL, CentOS, Ubuntu, or SLES.
1- Type virtual machine scale set in the Azure search box, select Virtual machine scale sets.
2- Virtual machine scale sets windows and then click the + add button.
3- Create a virtual machine scale set wizard.
Subscription – select your subscription
If you want to create new resource group then click create new. I am using existing one (my-rg).
4- Scale set details
Name – type a name (myscaleset).
Region – Select a region that is close to your area (Central US).
Availability zone – None
Image In this example, I have chosen windows server 2019 datacenter.
5- Type the desired username, and select which authentication type you prefer.
Select Next to move the other pages.
Leave the defaults for the Disks pages.
6- On the Networking page and then select virtual network.
7- Load balancing
Use a load balancer – select yes
Load balancing options – select Azure load balancer.
Select a load balancer – select myloadbalancer that we have created earlier.
Select a backend pool – select Create new.
8- Type a name mybackendpool and then select Create.
9- Click Next : Scaling >
10- In the Scaling tab
Instance
Initial instance count – select 2
Scaling
Scaling policy – select custom
Minimum number of instances – choose 2
Maximum number of instances – choose 10
11- When you are done, then select Review + create.
12- After passed the validation, so select create to deploy the scale set.
13- Virtual machine scale sets successfully created.
Virtual machine scale set overview
1- Virtual machine scale sets overview.
2- Under settings click instance.
3- Click settings and then select custom autoscale.
4- Custom autoscale.
5- Scale settings.
Leave a Reply
You must be logged in to post a comment.