Soru

Zorluk: OrtaConfigure Virtual Machine Scale Sets (VMSS)

You are designing autoscale rules for an Azure Virtual Machine Scale Set (VMSS) named `vmss-processing`. The scale set currently runs with a minimum of 2 instances and a maximum of 10 instances. The scale-out rule is configured to increase the instance count by 1 when the average CPU utilization exceeds 75% for 10 minutes.

You need to configure the scale-in rule to decrease the instance count by 1. To prevent instance thrashing (repeatedly scaling out and scaling in) immediately after a scale-out event occurs when the scale set has 2 instances, which CPU threshold should you configure for the scale-in rule?

  1. Decrease the instance count by 1 when the CPU utilization is less than 40%Cevap
  2. B
    Decrease the instance count by 1 when the CPU utilization is less than 55%
  3. C
    Decrease the instance count by 1 when the CPU utilization is less than 65%
  4. D
    Decrease the instance count by 1 when the CPU utilization is less than 70%

Cevap

Decrease the instance count by 1 when the CPU utilization is less than 40%
The correct option is the one stating to decrease the instance count when CPU utilization is less than 40%. When the scale set runs on 2 instances, a scale-out is triggered as CPU load exceeds 75%, meaning the total load is 150%. Once a third instance is added, the load is divided by 3, resulting in approximately 50% CPU load per instance. Setting the scale-in threshold to 40% ensures that the load must drop significantly further before scaling in, preventing thrashing.

Adım Adım Çözüm

1
Calculate the total CPU load of the scale set when it is running at minimum capacity (2 instances) just before a scale-out event is triggered.
Total CPU load is approximately 2×75%=150%2 \times 75\% = 150\%.
Determining total CPU load allows us to calculate how that load will be distributed among the instances after scaling out.
2
Calculate the expected CPU utilization per instance immediately after the third instance is added, assuming the workload remains constant at 150%.
New CPU utilization per instance is 150%3=50%\frac{150\%}{3} = 50\%.
This determines the new metric value that the scale-in rule will evaluate once the scale-out action completes.
3
Select a scale-in threshold that is lower than the new CPU utilization to prevent the scale-in rule from triggering immediately.
The threshold must be strictly less than 50% (e.g., 40%).
If the scale-in threshold is set to 50% or higher, the post-scale-out CPU load of 50% will immediately satisfy the scale-in condition, resulting in instance thrashing.

Anahtar Kavram

Autoscale rule thrashing and metric thresholds
Tahmini Süre:1m 30s
Bu soruyu puanla