Freigeben über


Dynamic Memory Pro Tip–be reasonable with your startup ram

Hyper-V now allows you to configure a startup, minimum and maximum memory limit.  If you are like me – you probably leave the startup ram at the default of 512mb – but you should really consider changing it to better suit your environment.  Here is a quick screenshot from one of my Hyper-V servers:

clip_image002

Two things that I have discovered:

  1. Some of my virtual machines benefit from having a startup and minimum that is below 512mb.  My FTP server, for instance, is a core installation of Windows server which just acts as an FTP server (and nothing else).  It happily boots and runs with a startup and minimum amount of 256mb ram.
  2. Other virtual machines benefit from having higher startup ram amounts.  I have never seen my TMG server under 2GB of ram – and have set the startup ram for this virtual machine to 2GB.

Why would I increase the startup ram for the TMG server?  Well – we do not start adding & removing memory dynamically until fairly late in the boot process for Windows (basically we wait until the system is mostly up and running before we start doing anything fancy with memory).  TMG loads a *lot* of processes before we start reacting with dynamic memory.

The result is that while this virtual machine will always run well at the end of the day (no matter what the startup ram value is) the amount of memory assigned for startup ram can have a profound impact on boot times.  When my TMG server has a startup ram value of 512mb it consistently takes ~10 to 15 minutes from cold boot to fully functional.  If I bump the startup ram to 2GB it boots and is functional in under 2 minutes.

The net result for me is that my system is fully functional a lot quicker after any servicing, and I have not had to give up any resource to enable this.

Cheers,
Ben

Comments

  • Anonymous
    February 26, 2013
    I believe this is also true for almost any application server (from SQL, to SharePoint, to Exchange). Although some are not supported with DM, they work pretty well with it - you only need to boot them with reasonable amount of memory (otherwise the boot times could go up to tens of minutes). An Exchange 2010 with FPE needed between 15 and 20 mins to boot with 4GB ram and under 5 with 16GB. But what is interesting for me is if HV page file is used when VMs with more cumulative startup memory than the host's (but with less cumulative minimum) are booting at the same time? And even if you delay some of those VMs' startup times, will HV "shrink" the also running (to their minimum) so that the others can boot successfully?

  • Anonymous
    February 26, 2013
    Nice tip. Just tried to apply it, but sadly the amount of startup RAM can only be changed when the VM is not running... I understand the technical reasons for that - but it's very annoying from a usability perspective. I understand that it's difficult to change it during runtime (since dynamic memory might not be active on a VM), but let me change it and update the value on the next restart of the VM. That'd be nice, because I don't want to shutdown VMs just to change configuration.

  • Anonymous
    February 26, 2013
    Speaking of dynamic memory: Will it be supported for Linux guests in the foreseeable future?

  • Anonymous
    February 28, 2013
    Now Linux support would be great :)

  • Anonymous
    April 27, 2013
    My SQL2012 with big tabular cubes need at least 10 GB for startup, otherwise analysis service won't start...

  • Anonymous
    January 22, 2016
    Hi, Thank you for sharing. Would you please recommend a set of performance counters to determine the cost of having a startup memory too low? Sorry if questions is to simple, however I am new to Hyper-V and I have to learn while solving critical problems. Thank you so much.

  • Anonymous
    January 26, 2016
    ChrisTX / Ubumem - Linux support for DM is now there! LulaMae - Unfortunately, I do not know of any good counters.  I would watch the boot time, and the memory pressure when the system is booted.