Availability Set vs Availability zone vs scale set

Aakib Dawood 0 Reputation points
2023-03-25T09:51:21.7166667+00:00

Can you please clarify the following points:

  1. Availability set allows us to only choose a region and then we define FD's and UD's. Considering a multi zone region, are the FD's and UD's of an availability set spread across multiple datacenters spanning multiple zones or only multiple datacenters within a single zone or only within a single datacenter in a single zone?
  2. Why do we even need a UD? Documentation says UD's are required for planned maintenance, but will the VM not be live migrated to another node before rebooting the current node? Then why would the VM require a reboot due to a maintenance activity on a node?
  3. In case of scale sets, i have read a few discussions in this forum wherein scale set is not associated with high availability. I fail to understand this because there are FD's in scale sets as well just like availability sets. Then form a high availability angle, how are scalesets and availability sets different?
Not Monitored
Not Monitored
Tag not monitored by Microsoft.
35,998 questions
0 comments No comments
{count} votes

4 answers

Sort by: Most helpful
  1. Sedat SALMAN 13,160 Reputation points
    2023-03-25T10:29:39.4166667+00:00
    1. Availability sets, fault domains (FDs), and update domains (UDs) in a multi-zone region:

    Availability sets are a feature within a single Azure region that help ensure high availability of your application by distributing VM instances across multiple fault domains and update domains. A fault domain represents a group of VMs that share a common power source and network switch, while an update domain represents a group of VMs that can be updated and rebooted together.

    In a multi-zone region, the FDs and UDs of an availability set are limited to a single zone. This means that the VMs in an availability set will be spread across multiple datacenters within a single zone, rather than spanning multiple zones.

    1. The need for Update Domains:

    The primary purpose of update domains is to ensure that your application remains available during planned maintenance activities. Although Azure does support live migration for certain maintenance tasks, not all updates can be performed without rebooting the VM. In cases where a reboot is necessary, update domains help minimize the impact on your application by ensuring that only a subset of VMs are rebooted at the same time. This allows the remaining VMs in different UDs to continue serving the application during the maintenance window.

    1. High Availability in Scale Sets vs. Availability Sets:

    Both scale sets and availability sets are designed to provide high availability for your applications. However, they serve different purposes and have some differences in how they achieve this goal:

    • Availability Sets: These are designed for applications that require a fixed number of VMs to be distributed across multiple fault and update domains. They ensure that the VMs are distributed in a way that maximizes their availability in the face of hardware failures or planned maintenance.
    • Scale Sets: These are designed for applications that can automatically scale based on demand. They also distribute VMs across fault and update domains, but the primary focus is on the ability to dynamically add or remove VMs based on load or other factors. Scale sets provide high availability through redundancy and auto-scaling, while availability sets provide high availability through redundancy and fault/update domain distribution.

    The main difference between the two lies in the way they handle scaling. Availability sets are designed for applications with a fixed number of VMs, while scale sets are designed for applications that need to automatically scale in response to demand. However, both options provide high availability by distributing VMs across fault and update domains.

    6 people found this answer helpful.
    0 comments No comments

  2. Erkan Sahin 830 Reputation points
    2023-03-25T10:40:10.6233333+00:00
    1. When using an availability set in a multi-zone region, the fault domains (FDs) and update domains (UDs) are spread across multiple datacenters spanning multiple zones. This provides additional resiliency by ensuring that VMs are spread across multiple zones within the region, which reduces the likelihood of a single point of failure.
    2. Update domains (UDs) are used to ensure that not all VMs in an availability set are updated or restarted at the same time during planned maintenance. While live migration can minimize downtime during planned maintenance, there may be situations where a VM needs to be rebooted during maintenance. In such cases, UDs help ensure that only a subset of VMs in the availability set are rebooted at a time, reducing the overall impact of the maintenance activity on the application.
    3. Scale sets and availability sets are different in terms of their focus on high availability. Availability sets are designed to ensure that VMs are distributed across multiple fault and update domains within a single datacenter or region to provide resiliency and reduce the likelihood of a single point of failure. Scale sets, on the other hand, are designed to provide horizontal scaling of VMs based on demand, and can be associated with an availability set to provide additional resiliency. While FDs are used in both scale sets and availability sets, the primary focus of scale sets is on scalability rather than high availability. However, when combined with an availability set, scale sets can provide a highly available solution.
    1 person found this answer helpful.
    0 comments No comments

  3. Erkan Sahin 830 Reputation points
    2023-03-25T10:40:30.1366667+00:00

    If further help is needed do not hestitate to reach out :-)

    0 comments No comments

  4. Aakib Dawood 0 Reputation points
    2023-03-26T06:19:27.56+00:00

    Ok so now i am very confused.

    1. Both of your answers differ in terms of whether availability set spans across multiple zones or not. Do you have any reference available?
    2. Erkan - I did not see the option to associate a availability set with a scale set. Can you explain how we can do that?
    3. Finally, If we set the scaling to manual and set the number of initial instances then both availability sets and scale sets are essentially doing the same thing with one difference, availability set allows us to define UD's while in scale sets there are only FD's, please correct me if i am wrong.
    0 comments No comments