VMWare

You are currently browsing the archive for the VMWare category.

VCP – EVC

EVC ,or enhanced vMotion Compatibility, is a feature that ensure vMotion capability within a cluster.  That is, you could possibly have a cluster that contains a mixed batch of servers.  Some that have newer Intel processors, some that have older Intel processors and so forth.  The problem is, that based on the feature set of the CPU, certain features are presented to the VM guest.  If you try and vMotion a server to a different guest that lacks that feature, vMotion will fail.  EVC takes into consideration the CPUs on all of the hosts in the cluster and basically computes the lowest common denominator.  It then present that feature set to the VM guests.  So even though a newer server might have a newer feature set, it would be masked by the hypervisor to ensure vMotion compatibility between other hosts in the cluster. 

EVC is turned on at the cluster level.  To enable EVC, right click the cluster and edit settings…

image

As you can see on my cluster, the EVC feature is turned off.  Let’s try and turn it on.  Click the ‘Change EVC Mode’ button…

image

For kicks, I tried enabling EVC for AMD hosts.  The compatibility checker immediately noticed that I actually have Intel based hosts.  Also, it noticed that the CPUs I do have are not compatible with EVC.  The CPU has to have a specific feature to support feature set masking and the processors I have don’t support it.

A couple of other quick notes to consider…

-EVC can only be configured on a cluster that doesn’t have any running guests.  This is to ensure that a feature currently in use by a guest doesn’t get taken away (masked) by EVC while it is in use.

-EVC masks features so in some cases, this can be undesirable.  Keep that in mind when you build the clusters.  Purpose built clusters are always a good idea in my mind.

-EVC can save you some pain when using things like DRS.  I’ve configured DRS before and then days later determined DRS wasn’t working.  It was because the hosts weren’t compatible. 

Tags:

Reservations and limits are configuration items that refer to memory and CPU.  Let’s give a quick definition of the term and then a demo of how that item impacts memory allocation.  CPU reservations and limits can be understood rather easily once we nail down the memory side of things. 

Reservation - The amount of CPU or memory that is guaranteed to that VM.  That is, if the host doesn’t have those resources free, the VM can’t even power on. 

The reservation setting has a number of impacts on the memory for a particular VM.  The first item it impacts is the VM swap memory.  If you recall from my last post, the VM creates a VM swap file for itself that is equal in size to that of it’s allocated memory.  This changes once you configure a memory reservation.  Let’s take a look…

image
So on this host, I’ve allocated 8 GB of RAM.  I’m also going to configure a 2 GB memory reservation…

image
Now, lets save these settings, and power up the VM.  Now let’s check the data store and see what it created for a VM swap file…

image
As you can see, the VM swap file is no longer the size of the allocated memory.  Rather, it’s the allocated memory -(minus) the memory reservation.  When you think about it, this makes perfect sense.  I’m guaranteeing to the VM that it will have 2 GB of physical host RAM.  That being said, it really only needs 6 GB of disk swap space.  

Despite having a memory reservation, the host memory isn’t automatically allocated to the VM when it powers on.  That is, the hypervisor still allocates RAM on an as needed basis.  However, it will always make sure that the memory to fill the reservation is available to the VM and not allocate it to other tasks. 

There are a couple of other memory definitions in vSphere that I’d like to define before we wrap up the memory reservation piece.

Memory Overhead – The amount of memory that the hypervisor believes is  required just to keep the VM running.  This memory gets allocated to VMkernel itself or other processes that are running to service VMs. 

Consumed Host Memory – This is the total amount of physical memory that has been allocated to this host.  This number can be larger than the total allocated VM memory since this number includes the Memory overhead total.

Active Guest Memory – This is the amount of memory that the hypervisor believes the VM is actually using.  This isn’t an exact number since it’s based off of statistical gathering and sampling. 

These numbers can all be found by looking at the summary tab of a particular VM…

image

Now, here’s is where it get’s confusing.  Click on the Resource Allocation tab next to the Summary tab….

image 
So let’s define some of these memory terms….

Consumed – Same as the Consumed Host memory definition.  This should equal ~ the private memory allocation plus the actual overhead consumption. 

Overhead Consumption – The amount of memory ACTUALLY be used as VM overhead.  Notice that this is different than the number we saw on the summary page which is really just an estimation. 

Private – The amount of memory that’s being allocated from physical memory on the host to the VM.

Shared - The amount of memory that’s being shared with other VMs through TPS (transparent page sharing).

Active - Same as the Active Guest memory Definition

Unaccessed – Sort of a mystery to me but it’s supposedly the amount of memory which has not yet been addressed by the host.

Swapped, Compressed, and ballooned should all hopefully read as 0.  If they didn’t, that would indicate those features were in use. 

Ok, so I just wanted to get those defined.  Let’s look at Limits now…

Limits – The Limit is to define how much actual physical RAM a VM can use.  The default setting for this is unlimited (meaning as much as you allocate to a VM).

So why would we ever want to limit the amount of physical host memory that a VM can use?  When we oversubscribe memory.  So let’s look at how we might configure this.  Let’s say we have a host that we’ve assigned 8 gig of memory to.  Now, we want the guest to think it has that much, but in reality, we cant actually let it have 8 gigs of RAM from the host ESXi box.  So we tell it that we for sure want it to have 4 gigs of host RAM (Set a reservation for 4 GB) but also tell it that we don’t want it to ever use more then 6 gigs of host RAM (set a limit for 6 GB).  In doing this, we tell the machine the following…

-You get a dedicated 4 GB of host RAM if you need it
-You can have up to 6 GB of host RAM if it’s available
-Anything over 6 GB of host RAM requested will get swapped out

image 

So this makes pretty good sense.  The same reservations and limits can apply to CPU.  But since I think I already beat the proverbial horse here, I’m going to call an end to this blog.

When you create a VM, you also create a VM Swap file.  This swap file is entirely different than the swap file that the guest OS uses.  I think we are all probably familiar with Linux swap partitions and windows page files.  When the guest OS is running out of memory, it can begin to swap to disk.  This all happens OS side and is not at all controlled by the hypervisor.  On the other hand, VM swap files are.  When a VM is powered on the hypervisor creates a VM swap file equal in size to that of it’s memory allocation.  For instance, this guest has a 2 gig memory allocation…

image
Since it’s powered off, let’s go take a quick look at the data store…

image
A bunch of files we expect to see, but no swap file.  Let’s boot the VM up…

image
Now we see the swap file (.vswp).  The VM will use the swap file when it runs out of physical memory.  This has a quite severe impact on VM performance and should be avoided it at all possible. 

« Older entries