VMware DPM Green Datacenters
July 31, 2012Now that we’ve entered the virtualization age, we’ve become accustomed to moving workloads between hosts in order to get better performance. We’re so used to it, that VMware DRS will move workloads around automatically and many administrators don’t even care what host is running their virtual machines. Hosts are now more like a resource container, where we move our servers to the resource that is most available.
VMware lets us take DRS one step further, where if we have extra resources available that aren’t being used, we can power off the hosts in order to save on power consumption. If we have 50 hosts running, but only using the resources of 30 of them, let’s power off the remaining 20 hosts to save on power and cooling. Over a year, these types of savings can really add up.
Set up DPM
The first step to setting up DPM should likely be to configure the power management settings on the host. Let’s think about it, if we’re going to be powering off servers, we’re also going to need a way to automatically start up the server so that it’s resources can be utilized again when needed.
There are three options to do this: Wake-on-LAN, IPMI, or iLO. If you are using either IPMI, or iLO you’ll need to configure the login informatin and IP Addresses of the Baseboard Management Controller. In the example below, I’m using iLO to connect to my host.
Go to the Hosts –> Configuration tab and select Power Management. Here you can set an IP Address and login info for each of your hosts.
Once your hosts have been configured then the cluster settings can be modified to utilize DPM.
DPM Cluster Settings
The DPM Cluster settings are much like DRS Settings. In fact they are under the vSphere DRS group in the cluster settings window. You can see that there is an off, Manual, or Automatic option, much like DRS has. “Off” does nothing with power management, “Manual” will make recommendations about what hosts can be powered off or should be powered on, and “Automatic” will power onoff machines by itself.
You can also set the threshold so that you can be more or less aggressive with your power saving options. If you are very conservative in your DPM Threshold, vCenter only powers on servers when needed, it will not power off hosts that aren’t being used. On the contrary, the most aggressive setting will power off servers if the resource utilization becomes lower than the target range, but will power on servers when needed.
I would be careful using either of the extremes. Too low and you might not be powering off servers and getting any benefits of DPM, but too high and you might be powering servers off and on very often which might cause more power usage from spinning up servers over and over.
DPM Host Options
As you would expect, you can customize your DPM Settings per host. Go to the host options and set how you want your DPM Hosts to act with regards to power management. This is also a good place to see if you’ve tested putting a host into Standby mode already.
Entering Standby Mode
If you’ve set your DPM Cluster to Automatic, you’re basically done but if you want to test out your hosts, or you’ve put your hosts into manual mode you can always shut down your hosts from vCenter. Right click the host and choose “Enter Standby Mode.” This will effectively migrate any virtual machines on the host and power off the server.
When your server is powered off from using Standby Mode, it doesn’t appear disconnected in vCenter like it might if it was rebooted. Instead it shows up as a host that is in standby. This allows you to right click the host again and choose “Power On” to boot the host and get it ready for more workloads.
Great post, Eric. DPM doesn’t get a lot of play. Two comments I’ll share on DPM –
1. In View, these standby hosts show up as an alert (red box). This is really a bad design on View’s part, but can throw false positives to your View team if they see a host alert and don’t know DPM is enabled. In other words – tell your View folks that you are using DPM.
2. In an environment where vCenter is managing itself (virtual within the cluster), I typically advise making a DRS rule that keeps it pinned to just a few hosts (easier to find it if the worst happens). I would then disable DPM on those hosts to ensure that vCenter always has the ability to move around with DRS if resources are constrained.
[…] setup with vSphere, I would usually configure the Distributed Power Management, mainly so I could power on and off my servers from the vCenter UI and not have to log in to each server individually to power them off or things. I was pleasantly […]