Link to home
Start Free TrialLog in
Avatar of nick loenders
nick loenders

asked on

What is best size for Pagefile in VM (Windows 2008 R2 host AND guest)

I have Hyper-V set up on a Windows 2008R2 and I created a VM with Windows 2008R2 and given it 4vCPU's and 24GB RAM. What size do I best give the Pagefile on my VM?
I read multiple things about this like 24GB+256MB.
BUT, why would I give it that many virtual memory (pagefile) as it already has 24GB of RAM?
Avatar of Rich Weissler
Rich Weissler

The common answer is so that the OS can perform a full memory dump when it crashes.  If that troubleshooting tool is useful and valuable to you, absolutely -- you'll want the pagefile that large.
Why would you give the VM 4CPU?  How many physical threads can the host handle?
Why not let Windows automatically handle the page file. That is the best way from my point of view.
If you want a detailed explanation Microsoft's Moti Bani has a blog on the subject.  https://blogs.technet.microsoft.com/motiba/2015/10/15/page-file-the-definitive-guide/
Hi,

You can set it to automatic for the system to take care of it. If you want to customize, them the min is 1xRAM & Maximum is 3xRAM or 4GB which ever is larger, for Win 2008 R2. Refer Below:-

https://support.microsoft.com/en-in/help/2860880/how-to-determine-the-appropriate-page-file-size-for-64-bit-versions-of

Thanks,
ABhi...
Avatar of nick loenders

ASKER

Well, let me add. The server is a RemoteDesktopServer.

Does it only use this pagefile for crashdumps??
No. Crash dumps are stored separately and Page File is used as Memory when needed. Any Windows System.
From the blog Lee linked earlier:
"[...]Windows is using the paging file as a placeholder for memory dumps, meaning that Windows is writing the crash dump first in the page file, and then the SMSS process copies it to a different memory dump file."
Which means, as a practical matter, if you're attempting to to save full crash dumps on a system with 24 GB RAM, you'll need 48 GB of disk space...
We normally save just recent Mini Dumps. This suffices for most things and they are vastly smaller.
My servers were first set to 18GB RAM and a virtual pagefile of 18+256. Now I changed the RAM to 24GB, but I don't have an extra 6GB free on my harddisk at the moment.

Will this give a problem?

On the other hand, if my system crashes I just reboot. If it is fnucked up, I reinstall an image instead of trying to figure out what happened.
ASKER CERTIFIED SOLUTION
Avatar of Rich Weissler
Rich Weissler

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
We generally set to Automatic

And have a virtual disk set aside for the purpose of page file this way it's separate to OS Disk does not get full can be excluded from backups and can easily be extended if the needs arise

Also the page file virtual disks can be more to faster storage if paging should occur

System Disk with low disk space should never occur and easily managed in a virtual environment
Crash dumps - who used these any more?

Do you suffer many BSODs not seen one in many years now with good behaviour of Guest OS and drivers and healthy hardware!
> Crash dumps - who used these any more?
Concur!  :-) However, it's what the old recommendation for pagefile settings were based upon.  Confirming first that the user does not have a requirement to save full crash dumps... and then, if they aren't a requirement, it can easily be said that the old recommendation can be ignored.  ;-)