Technical

vSphere 7 – Improved DRS

VMware vSphere Icon

The first release of Distributed Resource Scheduling (DRS) dates back to 2006. Since then, data centers and workloads have changed significantly. The new vSphere 7 release is shipped with DRS enhancements to better support modern workloads by using an improved DRS logic and new accompanying UI in the vSphere Client.

The enhanced DRS logic is now workload-centric rather than cluster-centric, as it was before with DRS. The DRS logic is completely rewritten to have a more fine-grained level of resource scheduling with the main focus on workloads. This blog post goes into detail on the new DRS algorithm, and explains how to interpret the metrics as seen in the new UI.

The Old DRS

vSphere DRS used to focus on the cluster state, checking if it needs rebalancing because it could happen that one ESXi host is over-consumed while another ESXi host has less resources consumed. DRS runs every 5 minutes, and if the DRS logic determined it could improve the cluster balance, it would recommend and execute a vMotion depending on the configured settings. That way, DRS used to achieve cluster balance by using a cluster-wide standard deviation model.

Image of the vSphere 6.7 and older DRS status pane

The New DRS

The new DRS logic takes a very different approach. It computes a VM DRS score on each host and moves the VM to the host that provides the highest VM DRS score.

The biggest change from the old DRS version is that it no longer balances host load directly. Instead, it improves the balancing by focusing on the metric that you care most about: the virtual machine happiness. Important to note is that the improved DRS now runs every minute, providing a more granular way to calculate workload placement and balancing. This results in overall better performance of the workloads.

Image of the vSphere 7 DRS status pane, cluster score is 85%

VM DRS Score

The new DRS logic quantifies virtual machine happiness by using the VM DRS score. First, let me emphasize that the VM DRS Score is not a health score for the virtual machine! It is about the execution efficiency of a virtual machine. The score values range from 0 to 100% and are divided into buckets; 0-20%, 20-40%, and so on.

Obtaining a VM DRS score of 80-100% indicates that there is mild to no resource contention. It does not necessarily mean that a virtual machine in the 80-100% bucket is doing way better than a virtual machine in the lower buckets. That is because there are many metrics that influence the VM DRS score. Not only performance metrics are used, but capacity metrics are also incorporated in the algorithm.

The performance drivers for the VM DRS score are contention based, using metrics like CPU %ready time, good CPU cache behavior, and memory swap. The reserve resource capacity, or headroom, that a current ESXi host has is also taken into account to determine the VM DRS score. Will the virtual machine be able to burst resource consumption on its current host and to what level? Are there other ESXi hosts in the cluster that have more headroom available? All these factors play an important role in the calculation of the VM DRS score.

Image of the vSphere 7 DRS status pane, cluster score is 70%

The improved DRS is no longer thinking about the relative load between ESXi hosts in a cluster, the main focus is on the happiness of the workloads. Next to VM DRS Score, DRS presents the Cluster DRS Score in the UI. It is calculated using an aggregation of all the happiness VM scores in the cluster. DRS will try to maximize the execution efficiency of each virtual machine in the cluster while ensuring fairness in resource allocation to all virtual machines.

The vSphere cluster summary overview provides insights on what is happening from a DRS perspective.  If you require more information on VM DRS Score, the new UI will provide that information to you.

View All VMs

When clicking on the ‘View all VMs’ option in the cluster summary DRS view,  you will be presented an overview of all virtual machines in the cluster and more detailed information about their resource claim and entitlement.

There might be situations where you will see a lot of CPU stress, which appear as high CPU ready times (%RDY) in the CPU Readiness column, or a large amount of swapped memory. Those are indicators that the workloads have possibly depleted the cluster compute resources.

You can use this information to move workloads to other clusters, or to scale out the cluster resources by adding additional ESXi hosts. The latter we can do automatically in VMware Cloud on AWS using Elastic DRS.

UI Walkthrough

When you click on the cluster “Summary” overview in vSphere 7, the new DRS UI is shown on the right. Expand the DRS view to get immediate insights. Check out this UI walkthrough to get an understanding of what it looks like:

New Capabilities in DRS

The new DRS logic in vSphere 7 is an important step forward for running modern workloads. Additional new capabilities that tie in with, or are a part of, DRS are Assignable Hardware and Scalable Shares.

Assignable Hardware

When a VM configured with hardware accelerators is first powered on it needs to be placed on an appropriate host in the cluster. The Assignable Hardware framework integrates with DRS to do that. PCIe devices with the new Dynamic DirectPath I/O or NVIDIA vGPU profiles are supported in vSphere 7 as part of this initial placement. This video includes more information on how this works, and more detailed information will follow in an upcoming blog post.

Scalable Shares

An important update to DRS is the option for Scalable Shares. Enabling Scalable Shares allows resource pools to have dynamic & relative entitlements. If you’ve used resource pools you’ve likely seen a situation where resource pools configured with higher share levels would not necessarily guarantee more resources for their workloads. This solves that! An improvement like this is also important for vSphere with Kubernetes, as the vSphere Pod Service needs this to ensure performance. The following video has more information, and more detailed information will follow in an upcoming blog post.

To Conclude

DRS is providing a very fundamental and important functionality as part of our virtual infrastructures since its first release. These important enhancements in vSphere 7 mean that workloads will perform as close to optimal as possible, while ensuring that hardware is used very efficiently, and help vSphere Admins add GPUs and hardware accelerators to workloads.

Watch the following video to learn more about the DRS improvements in vSphere 7.

 


We are excited about vSphere 7 and what it means for our customers and the future. Watch the vSphere 7 Launch Event replay, an event designed for vSphere Admins, hosted by theCUBE. We will continue posting new technical and product information about vSphere 7 and vSphere with Kubernetes Monday through Thursdays into May 2020. Join us by following the blog directly using the RSS feed, on Facebook, and on Twitter. Thank you, and please stay safe.