Monday, November 1, 2010

What has changed for Hyper-V Dynamic Memory with RC release of 2008 R2 SP1

Microsoft has released the RC version of 2008 R2 SP1 and I was able to take out sometime this week to do my hands dirty on it by uninstalling the previous beta version and installing the RC version. I see that there have been some interesting changes for Hyper-V Dynamic memory [DM] feature based on the feedback provided and these changes span from GUI based to functionality based and address the issue of logarithmic behaviour of DM.

Before RC

In RC release we see changed GUI for DM and see new terms which can be seen below.

Assigned memory : Physical memory used by the VM.
Memory demand: Total committed memory in the VM [memory needed to run with reasonable performance] and if this memory is less than assigned memory, VM will use guest paging and you will see a memory warning status in Hyper-V GUI.
Memory status: Gives an indication about the memory status of VM for e.g. OK, Low, Warning.

If you carefully look at memory buffer setting, it has also changed in sense that earlier you had a slider moving from 5-95% however now you just have a input box for the memory buffer value where the minimum value can be 5% and max 2000%. Assigned memory ideally is memory demand+memory buffer and this new change takes care of the memory buffer algorithmic behaviour in beta version.

Memory Priority has been renamed as Memory weight however no other changes than the cosmetic name change to make it similar like cpu weight.

In the above  mentioned screenshot you can see that my SCOM VM needs around 1054MB ram but has been assigned only 1024 MB and thats why we see a warning status. What it means is that VM will initiate guest paging to take off some of the memory pressure and if you have same situation in beta version you will see negative memory availability at this stage which was confusing some customers. So i will say this is a welcome change for end users. Nothing has changed at the front of DM performance counters as seen below.

 Another welcome change is that with the RC build you can now enabled Dynamic Memory on the standard and web editions of Windows Server too by following below mentioned procedure.

Windows Server 2003 / Windows Server 2003 R2
Update the integration services.

Windows Server 2008
Install sp2 and then install this hotfix: inside the virtual machine. Finally you will need to update the integration services.

Windows Server 2008 R2
Instead of updating the integration services – you need to install the release candidate of service pack 1 inside the virtual machine otherwise you get the following dummy error message even if you update the integration services.

Memory pressure perfmon counter is nothing but ratio of memory demand and assigned memory as seen below and helps in understanding the allocation of memory among the guest machines.

You will be surprised to see in screenshot below that though for DC VM the assigned memory is more than sufficient why is memory status showing low???

So low means that the virtual machine has more than the memory demand, but less than 80% of the memory buffer and at that time as i increased memory buffer suddenly from 20-1200%, VM was trying to get more memory from DMVSP.sys and we saw low mem status for a couple of seconds. I must say that DM is very robust and very quickly grabs and releases memory based on buffer and priority settings. However If no other VM needs memory and i decrease the buffer of a particular , by design it takes 5 minutes to release that memory.

We still have MemoryReserve registry key for reserving host memory if required as mentioned here. I will keep testing and sharing Dynamic memory feature findings and hope you like this article. My earlier articles on Dynamic memory can be read here and here along with a webcast recording.


Blog is based on my Personal understanding of the Technologies mentioned above and information provided is AS IS.