Archive

Posts Tagged ‘virtualization’

The Poor Man’s Capacity Management for VMware in 6 Steps. Doing it the Old Fashion Way.

Capacity management is an important part of infrastructure and deployment planning. A capacity plan supports the goal of optimum and cost effective provisioning of organizational resources and services by matching them to business requirements. The capacity plan helps identify and reduce inefficiencies associated with either under-utilized resources or unmet customer expectations. One key objective is to provide appropriate service levels in a cost-efficient manner. The plan also helps ensure that all infrastructure components are capable of efficiently performing all required functions, and accommodate projected growth.

Now, you may be asking yourself why would you do it the old fashion way vs purchasing a trending and modelling software that makes your life easy? First off, those tools are very expensive and for some enterprises where IT is not a “driver”, the business case to buy these tools are very hard to make. Second, doing it this way will help you understand your environment better since it requires you to look a little deeper.

1.Identify Over/Under Subscribed Resources for VM

Capacity sizing is not an exact science. In certain circumstances, hardware resources are either oversubscribed and in others, they are under-subscribed  In order to optimize resource usage, periodic checks must be done in order to ensure the VMs are right-sized. Some companies do not currently have any specialized tool to help with the sizing process; therefore the guidelines as seen below can be used (note: these values can be different depending on your needs and your specific infrastructure)

Un-optimized VM Resource Indicators

Resource

Metric

Indicator

Comment

2 or more vCPU

vCPU % Utilization

<25%

Under Utilized

1 or more vCPU

vCPU % Utilization

>75%

Over Utilized

vRAM

Guest Memory Utilization

<25%

Under Utilized

vRAM

Guest Memory Utilization

>75%

Over Utilized

Datastore

Disk Usage

>80%

Over Utilized

VMDK Disk

Disk Usage

<20%

Under Utilized

VMDK Disk

Disk Usage

>80%

Over Utilized

VMs with memory or CPU reservations should be excluded from this analysis. Reservations are usually used for mission critical applications and applications that have been flagged as having very high resource usage. Reservation on VMs usually aligned with your defined SLAs

2.Adjust VM Settings to Optimize Resource Utilization

It was and maybe still is a recommended practice to create pre-determined VM sizes, and then fit the VM in one of the pre-determined configuration which closely aligns with its resource requirements. The preset configurations are not designed for Tier-1/mission critical apps since those types of applications may have a different characteristic which need to be sized according to vendor recommendations (e.g. Sharepoint, Exchange, SAP, Oracle, SQL…)

The following is an exmaple of the pre-determined configurations, again, this may vary on your needs:

Small

Medium

Large

1 vCPU, 1GB vRAM

2 vCPU, 2GB vRAM

4 vCPU, 4GB vRAM

1 vCPU, 2GB vRAM

2 vCPU, 4GB vRAM

4 vCPU, 8GB vRAM

1 vCPU, 4GB vRAM

2 vCPU, 8GB vRAM

4 vCPU, 16GB vRAM

The goal is to adjust VM resources whereas the average percentage of vCPU usage falls between 25% and 75% (as close to 50% as possible). In addition, the active memory (i.e. guest memory utilization) should fall between 25% and 75% utilization (as close to 50% as possible). This will allow the VM some headroom when spikes in either vCPU or vRAM occur.

This process requires planning maintenance windows, change requests, approvals and application/service down time. The recommended path to execute this is using an already defined maintenance window (patch upgrade, required reboot, etc…). This step may require an additional amount of effort the first time it is done; it will take much less time.as it’s maintained on a periodical basis.

3. Determine Current Resource Baseline

Determining the current resource baseline is the process of adding up all of  currently used and unused resources in terms of CPU, Memory, and Datastore space. There are two ways to do this:

  1. Logically split up resource pools by individual ESX Clusters.

For each cluster add up the amount of free and used CPU, Mem, Datastore (this can be extracted from the summary page of each host in the cluster using the vCenter client.

2.  Use RVTOOLS 3.4 software. This is a freely provided inventory tool that allows gathering data from the VMware environment and exporting it to Excel format for easier manipulation.

4.Determine Current Resource Ceiling

Determining the current resource ceiling is the process of determining the threshold for physical resource usage level. Beyond this threshold, additional resources need to be added to the cluster.

  • Calculate the amount of free resources (cpu/mem) needed in the cluster to withstand a host failure. This is required since this is the true resource ceiling that we need to plan for. This is also known as N+1 sizing.
  • For disk space, calculate a reserve of 20% on each Datastore for emergency VM expansions.

5.Forecasting based on Historic Trending

A method for forecasting future hardware resource requirements is through historical trending. By plotting past resource usage and estimating a linear trend, future requirements can be projected through extrapolation. Doing so will give us a good idea of where our resource usage is headed for and how much time we will have left with our current hardware configuration.

In order to do this, several things need to be analyzed:

  1. The maximum capacity
  2. The current utilization of resources
  3. The change of utilization over time

In order to determine how utilization is changing over a specific period of time, utilization samplings must be collected at regular intervals. This information should then be plotted on a graph and/or spreadsheet for easier readability.

Once the trend is calculated, the forecast scenario can be built.  The results of forecasting will always be estimates of what may occur in the future.  There are different methods that can be used to gain better accuracy, but it is simply not possible to state that we can forecast exactly what is going to happen. This is due to organic growth and new business requirements occurring in the environment. See the graph below as an example.

cap1

6.Resource Changes and the Effects on Time remaining

Virtual or physical Resource changes impact the amount of time capacity will be available; either positively or negatively. It is important to understand that in any type of computing environment there is almost never a completely linear growth trend. Changes can impact the environment, resulting in the trend shifting up or down. The shift will cause the amount of time remaining of the capacity to shorten or extend. Below are examples of situation which can affect time remaining of capacity, also known as “what-if” scenarios.

  • What If capacity is added? (e.g. add a new server to a cluster)
  • What If I capacity is removed? (e.g. host failure in the cluster)
  • What if I assign/remove resources to certain VMs?

The types of changes that may occur usually fall in one of the follow categories:

  1. Increase in resource capacity
  2. Decrease in resource capacity
  3. Increase in resources consumed
  4. Decrease in resources consumed

Any one of these adjustments will impact the utilization since:

UTILIZATION% = Consumed / Capacity

The graph below is a visual example of how a resource adjustment can shift the forecast and extend the time remaining until the resource ceiling is reached.

cap2

I’m open for comments and suggestions!

Follow

Get every new post delivered to your Inbox.

Join 109 other followers

%d bloggers like this: