are available for a much lower price than normal VMs and can significantly reduce the costs of running certain workloads or allow much more work to be performed at a greater scale, for the same cost. However, low-priority VMs do have different characteristics and are only suitable for certain types of application and workload. Low-priority VMs are allocated from surplus capacity and therefore availability varies – at times VMs may not be available to allocate and allocated VMs may occasionally be preempted by higher-priority allocations. The availability SLA for normal VMs therefore does not apply to low-priority VMs.
If applications can tolerate interruption, then use of low-priority VMs can significantly lower compute costs. Suitable workloads include batch processing and HPC jobs, where the work is split into many asynchronous tasks. If VMs are pre-empted, then tasks can be interrupted and rerun; job completion time can also increase if capacity drops. Low-priority VMs are initially only available through
, which provides job scheduling and resource management for batch processing workloads. Azure Batch pools can contain both normal and low-priority VMs; if low-priority VMs are pre-empted, then any interrupted tasks will be requeued, and the pool will automatically attempt to replace the lost capacity
Process to using Low Priority nodes
Once you've defined the parameters of your cluster, all you need to do is declare the cluster as a backend for the
. The body of the
loop runs just like a
loop, except that multiple iterations run in parallel on the remote cluster.