...building hybrid clouds that can support any device from anywhere
In this post I’ll explain a specific recommendation in setting up the Startup RAM parameter of Dynamic Memory (DM) and how it can be used in System Center Virtual Machine Manager (SCVMM) for Virtual Machine (VM) placement.
Dynamic Memory, introduced in Windows Server 2008 R2 Service Pack 1 (SP1), defined Startup RAM as the minimum amount of memory that a virtual machine can have. However, Windows requires more memory during startup than the normal operation. As a result, administrators sometimes assign extra memory for Startup RAM which Hyper-V cannot reclaim from the virtual machine after startup.
To overcome this, in Windows Server 2012, Dynamic Memory introduces a Minimum RAM setting, which allows Hyper-V to reclaim unused memory from virtual machines after startup. Using this feature, administrators can now set the Startup RAM with a memory larger than the Minimum RAM.
Also Windows Server 2012 introduces “Smart Paging” approach for reliable virtual machine restart operations. “Smart Paging” comes in place when Hyper-V cannot allocate the memory set in the Startup RAM which is greater than the Minimum RAM for the restart of the virtual machines. “Smart Paging” uses disk resources as additional, temporary memory to assign the extra memory needed by the virtual machines for startup. While this approach provides a reliable way to keep virtual machines running when there is no available physical memory, it can degrade the virtual machine performance due to slow disk access speeds which can be improved by setting up the paging on some fast storage devices such as SSD.
In order to reduce the impact on the “Smart Paging”, Hyper-V relies on the paging operation on the guest operating system, and after starting the virtual machine, Hyper-V removes the additional memory from the virtual machine by coordinating with the Dynamic Memory components inside the guest operating system (a process sometimes referred to as “ballooning”). By this technique, the use of paging is temporary and not expected to be longer than 10 minutes.
When deploying virtual machine that needs more startup memory, the recommendation is to configure the Startup RAM parameter equal to the Maximum RAM. This ensures the virtual machine starts with the total amount of memory configured and with the dynamic memory balloon driver enabled for the paging operation.
While SCVMM allows to configure the Startup RAM parameter equal to the Maximum RAM in the virtual machine template and configuration, when deploying the virtual machine the placement algorithm looks for the Startup RAM parameter rather than the Minimum RAM for finding the right host or assigning the host star ratings for placing the virtual machine.
If SCVMM placement cannot find a host that has more or equal physical memory than the Startup RAM then the placement fails and assigns “zero” star ratings for the hosts, but still allows the administrator to place the virtual machine by overriding the placement result.