SQL Server Health Check

Optimal Window’s OS Page File Settings For SQL Server

Mark Varnas
No comments

What is the Windows OS page file?

This file is a form of virtual memory.

When your memory RAM becomes full, Windows moves data from your memory RAM to your hard drive, placing it in the page file (also known as the swap file).

You never want your SQL Server to start paging.

SQL Server tends to go pear-shaped when its memory is paged to disk.

Optimal SQL Server Page File Size Settings

By default, the page file is auto-managed by Windows.

You don’t want to trust the management of page files to Windows, as it won’t do what is optimal for SQL Server.

The size of the page file depends on:

  1. the requirements of the system crash dump settings, and
  2. the peak or expected peak usage of the system’s commit charge.

Both considerations are unique to each system, even for identical systems.

The old rule of thumb (page file size = 1.5 or 2 times the RAM) makes no sense in modern systems.

The current logic is: the more RAM you have, the less you need a paging file.

So, how should you size your page file?

It depends on the specific workload and the type of server.

Having worked with various server configurations and applications, I’ve found that when sizing the page file, considering our application’s memory needs and crash dump settings is crucial.

I would say that a good point to start is to set an 8-12 GB size for Kernel Memory dump on the System with up to 256GB RAM.

How can I change the Windows file size?

You can configure the SQL Server page file by using System Properties as follows:

  1. Run sysdm.cpl
  2. Go to Advanced
  3. Select Settings under Performance
  4. Go to Advanced (again)
  5. Change under Virtual Memory

Note: Make sure to set SQL Server max memory settings correctly.
There are some best practices on how to configure this here.

More information:

Article by
Mark Varnas
Founder | CEO | SQL Veteran
Hey, I'm Mark, one of the guys behind Red9. I make a living performance tuning SQL Servers and making them more stable. I channel my SQL into our SQL Managed Services, SQL Consulting and our internal database products.

Leave a Comment

Managed SQL Server services, consulting, and emergency support from expert DBAs to improve performance, predictability, and cost.

Get started with Red9 today.

Contact us

Discover More

Discover what clients are saying about Red9

Red9 has incredible expertise both in SQL migration and performance tuning.

The biggest benefit has been performance gains and tuning associated with migrating to AWS and a newer version of SQL Server with Always On clustering. Red9 was integral to this process. The deep knowledge of MSSQL and combined experience of Red9 have been a huge asset during a difficult migration. Red9 found inefficient indexes and performance bottlenecks that improved latency by over 400%.

Rich Staats 5 stars
Rich Staats
Cloud Engineer

Always willing to go an extra mile

Working with Red9 DBAs has been a pleasure. They are great team players and have an expert knowledge of SQL Server database administration. And are always willing to go the extra mile to get the project done.
5 stars
Evelyn A.
Sr. Database Administrator

Boosts server health and efficiency for enhanced customer satisfaction

Since adding Red9 to the reporting and DataWarehousing team, Red9 has done a good job coming up to speed on our environments and helping ensure we continue to meet our customer's needs. Red9 has taken ownership of our servers ensuring they remain healthy by monitoring and tuning inefficient queries.
5 stars
Andrew F.
Datawarehousing Manager
See more testimonials