Rightsizing Virtual Machines with vRealize Operations 8.10
Virtual Machine Rightsizing is the process of optimizing the resources of a virtual machine to match its actual usage by analyzing its CPU and memory. This helps ensure efficient workload performance and reduce costs. VMware vRealize Operations can automate the process by suggesting changes to optimize resource allocation, resulting in improved performance and higher resource utilization.
In another post, I explained how to install and configure vRealize Operations. If you missed it, you can read it at the following link.
Log in to your VMware vRealize Operations (vRops) web interface and from the left menu click Rightsize under Optimize or from the home page select Rightsize.
Once you click on Rightsize you will be redirected to the following page which presents an overview of the oversized and undersized virtual machines in the corresponding data center. At the top of the page under Rightsize title, you will see your data centers if you have more than one data center! Since I only have one active data center, only Germany is shown.
The oversized VM section presents a full summary of what we can claim from virtual machines and how much that is. For instance, I can reclaim 40 CPUs and 76 GB from my virtual machines, and the total number of virtual machines that can be reclaimed is 20 virtual machines, although the size of the reclaim is not equal between virtual machines.
On the other hand, the undersized VM section provides you with an overview of the virtual machines that have been identified as undersized and require additional resources.
If we go down the page, there are two tabs that are Oversized VMs and Undersized VMs. The Oversized VMs tab contains all oversized virtual machines and the Undersized VMs contain all undersized virtual machines. In front of each cluster, you will see the resource usage you can save or should add in terms of CPU and memory, depending on which tab you are in. When you expand the cluster, the virtual machines under that cluster and their current configurations are displayed, along with their specific recommendations.
When you select one or more virtual machines, you can perform the following 4 actions on these virtual machines. Let’s explain each of these actions with an example.
Allows you to schedule one or more resize actions for oversized or undersized virtual machines. Select one or more virtual machines and click SCHEDULE ACTION, a pop-up appears where you must enter a name and a description (optional) and specify when to perform the action, for example, I have selected one virtual machine to reclaim 2GB of memory and 2 virtual CPUs, and I want to run this task at 2:30 PM. After that, vRops initiates the resize, and it uses its connection to vCenter to make the changes to the virtual machine. It even knows about hot-add and skips restarting the virtual machine if hot-add is enabled.
Hot-plug memory and hot-add CPU are features that allow you to add more resources when virtual machines is powered on! but they do not allow you to decrease the resources; You shut down the virtual machine and then decrease resources. So, whether enabled or disabled, if your virtual machines are oversized, they need to be shut down!
Since this virtual machine is oversized and I want to decrease its resources, I expect a reboot for this virtual machine.
If you check the virtual machine in the vCenter, click on Tasks under the Monitor tab. You should see 3 tasks, the first task is to shut down the virtual machine, the second task is to apply a new configuration and the third one is to power one virtual machine, without any interactions!
You can also check the status of the task in vRops under Automation Central. As you see it is successful!
If you want to apply the new configuration immediately, click Resize VM to do so in action. A pop-up window appears, select the box at the bottom of the screen to indicate that you agree that some work may be interrupted, and then select Resize VM. Since this virtual machine has hot-plug memory enabled and is undersized, I do not expect the vCenter to shut this virtual machine down to apply the change.
A new window appears indicating that the job has started and may take some time.
Like the previous virtual machine, If you check the virtual machine in vCenter, you should see only a task for applying the new configuration! without requiring a restart and without any interaction!
You can also confirm it in vRops. This time you can not see the task in the Automation Centeral, because you run it immediately and Automation Centeral is about automated jobs. To check the task go to Recent Tasks under Administration.
Here you can see all tasks, including automated ones. Our task was successfully executed at 4:40 PM.
If you want to leave oversized or undersized virtual machines and not receive any notification about them, select one or more virtual machines and click Exclude VM(S) button. A pop-up window will appear and tell you that in addition to resources, cost savings will not be considered for reclaim. Click Exclude VM(S) to exclude the virtual machine or machines.
If you click on Show Excluded VM at the bottom of the page, it lists the virtual machines that you excluded.
Exports the list of all virtual machines that are oversized or undersized to a CSV file. Depending on which tab you are on, these virtual machines will be exported. For example, If I am on the Oversized VMs tab, and click the Export All button, all oversized virtual machines are exported to a CSV file.
Hope this is informative for you!