From the course: vSphere 6.7 Professional Part 07: Resource Management

Create a DRS cluster in vSphere 6.7

- [Rick] In this video, I'll demonstrate how to create a DRS cluster in the vSphere Client. So, here you can see I'm at the home screen of the vSphere Client, and I'm going to start by clicking on hosts and clusters. And in my inventory, I have two ESXi hosts. So I'll start the process by right-clicking on my training data center and choosing new cluster. And I'm just going to call my new cluster Rick Demo. And that the moment, I have three features I can potentially enable. Now high availability is going to give me failover. If one of these ESXi hosts fail, the virtual machines will reboot on another host. I'm going to leave that disabled at the moment. And virtual SAN allows me to use the local storage of these ESXi hosts to create a shared data store. Again, I'm going to leave that setting disabled. But I am going to turn on distributed resource scheduler, or DRS. And I'll go ahead and hit okay here. And here's my new cluster. So, let's go ahead and configure some of the settings for this cluster, before I add any ESXi hosts to it. So I'll just right-click my cluster and hit settings. And under DRS, I can see that DRS is turned on. I'm going to go ahead and click on edit here, and modify some of the configuration settings of this DRS cluster. And the first setting that I need to choose is the automation level of the DRS cluster. So let's start with manual, because manual is a great way to initially establish a DRS cluster, especially if you're not overly familiar with DRS. So with manual, the automation level specifies that virtual machines in this DRS cluster will never be automatically moved around. That's what DRS does. It moves virt machines from host to host using vMotion. And so if I configure this manual automation level, what that means is that DRS is never going to automatically migrate VMs for me. What it will do is it'll generate recommendations. It'll watch the resource utilization across my cluster, and if it sees an opportunity to improve performance, it'll give me a recommendation. So that's manual. In partially automated mode, what happens is if I have a virtual machine that I try to power on and it's inside of that cluster, DRS will automatically choose the ideal host to run that virtual machine on. This is called initial placement. So with partially automated DRS, virtual machines will never be automatically migrated. It's not going to move running virtual machines around. But if I power on a VM, it'll pick the ideal host, based on the memory and CPU usage, and some other factors. It'll pick the ideal host for that VM to power on. And then finally, fully automated mode. This is where we're really turning over the control to DRS. We're saying DRS can automatically migrate virtual machines from host to host, using vMotion. And so we're going to let DRS automatically do all of this stuff. It's not going to generate recommendations for me. When it sees an opportunity to improve performance, it'll just move virtual machines around at that point. And so fully automated is really kind of the ideal way to run DRS. Now, I have to make sure that my vMotion configurations are in good shape. I have to make sure that my VMs can easily vMotion from host to host without any vMotion compatibility issues. So in order for fully automated DRS to work properly, I need to make sure the vMotion's working properly throughout my cluster. And then I can choose the migration threshold. Anywhere from conservative to aggressive. So in most scenarios, you want to leave this at the default. Right in the middle here of conservative and aggressive should be your setting, unless you have a reason to change it. With conservative, DRS will only apply recommendations to satisfy cluster constraints. Like for example, if I try to put a host in maintenance mode, all of the running virtual machines need to get moved off of that host. That's a migration that DRS will automatically perform. If I have virtual machines that have an anti-affinity role, virtual machines that are not allowed to run on the same host, I want to keep 'em apart, those recommendations will be applied in conservative. And if I go up to level two here, DRS will then start to make some moves for performance improvement, but only when workloads are extremely imbalanced. So if I have a real resource problem on one host, it'll start to migrate VMs off of that host. Kind of the middle of the road here, right in the middle at level three, DRS is going to look for hosts and look for moderate imbalances of workloads. So if a fairly significant performance improvement can be made, then DRS will carry out a vMotion. And this is normally the ideal. I don't want a whole lot of vMotions occurring, unless they're actually going to help with the performance, because every vMotion that you carry out has an impact. It takes up network bandwidth, and it utilizes CP resources to make that vMotion happen. So if I adjust the slider up to four or five, DRS is going to become much more aggressive. It's going to look for migration options that produce a relatively marginal improvement in performance. And so, this is going to mean more vMotions. It's going to move virtual machines around more frequently. And so unless I have a really strong need to do that, I'll typically just leave the slider at three, and go with the default configuration for migration thresholds. So, those are the different automation levels and the migration threshold adjustments that we can make with DRS. And then finally, the last two settings that I want to look at here on the automation screen, do I want to enable predictive DRS? So, what predictive DRS will do is it'll allow vCenter to retrieve information from vRealize operations, to potentially migrate VMs before resource contention occurs. So vRealize operations is sitting there analyzing all the performance of my ESXi hosts, looking at all these metrics. And if it sees a situation developing, or a pattern emerging, where potentially a resource problem is going to happen in the future, predictive DRS can be invoked to migrate virtual machines before that resource problem happens. So that's predictive DRS. I'm going to leave that disabled here. And then last but not least, virtual machine automation. So for virtual machine automation, I'm basically deciding do I want the ability to go to individual VMs and change their automation level? So right now, I'm setting up fully automated DRS on the entire cluster. But there may be certain virtual machines that would work better under manual automation. Like maybe vCenter, for example. I probably don't want vCenter being migrated around. I want to know what host it's running on, so I can find it if I need to. So I'll leave that box checked to give myself those options to override that automation level on an individual virtual machine basis.

Contents