Q: Explain the difference in scaling strategies for compute-intensive vs I/O-intensive workloads in Azure.
Architectural comparison and scaling strategies for compute-heavy workloads versus storage/network I/O-heavy workloads in Microsoft Azure.
Want to master this scenario in a live sandbox? Stephane Maarek's AWS Certified DevOps Engineer Professional Masterclass on Udemy covers this exact problem with hands-on terminal drills.
🛠️ Production Runbook & Step-by-Step Resolution
Compute-Intensive Scaling Strategy
Key characteristics and optimizations: - **Azure SKUs**: Select Fsv2 or FX-series instances (high CPU-to-memory ratio, up to 3.7 GHz clock speed). - **Autoscaling Metric**: Scale horizontally using CPU utilization (`Percentage CPU > 70%`) or custom queue depth metrics. - **Optimization**: Run lightweight OS kernels, disable unnecessary background daemons, and pin threads to vCPUs via CPU core pinning (`isolcpus` / NUMA architecture).
# Azure VMSS Compute Autoscaling Rule based on CPU
az monitor autoscale-rule create \
--resource-group rg-compute \
--autoscale-name autoscale-algo-trading \
--scale out 2 \
--condition "Percentage CPU > 75 avg 5m"
I/O-Intensive Scaling Strategy
Key characteristics and optimizations: - **Azure SKUs**: Select Ebdsv5 or Lsv3-series instances (high memory-to-CPU ratio, up to 260,000 IOPS and local NVMe storage). - **Autoscaling Metric**: Never scale on CPU. Scale on storage IOPS consumption, disk queue depth, or network bandwidth saturation. - **Disk Architecture**: Enable Premium SSD v2 or Ultra Disk with disk bursting. Crucially, turn on **Host Caching (Read-Only / Read-Write)** to serve queries directly from the VM's RAM cache without consuming disk IOPS.
Network I/O Scaling: Accelerated Networking
For high packet-per-second workloads, enable **Azure Accelerated Networking** (SR-IOV bypasses the hypervisor host switch, slashing network latency to under 30 microseconds and eliminating packet drops).
# Enable Accelerated Networking on Azure NIC
az network nic update \
--name nic-banking-db \
--resource-group rg-banking \
--accelerated-networking true
Architectural Summary: Horizontal vs Vertical
Compute-intensive tasks scale horizontally across cheap ephemeral instances with high elasticity. I/O-intensive workloads typically scale vertically (larger memory and local NVMe storage) or shard partitioned data horizontally across specialized stateful clusters.
- Use Fsv2-series for compute-intensive apps; scale horizontally based on CPU metrics and queue depth.
- Use Ebdsv5/Lsv3 NVMe series for I/O-intensive apps; scale based on disk queue depth and IOPS limits.
- Enable Host Caching and Premium SSD v2 to maximize disk throughput.
- Mandate Azure Accelerated Networking (SR-IOV) to bypass hypervisor network latency on high-throughput workloads.