Network Management

Calculate the maximum memory setting for SQL Server

Guide to calculating and adjusting Maximum server memory on the single instance of the MS SQL Server.

First published date

10/15/2018 1:00 PM

Last published date

5/7/2025 12:28 PM

Overview

When you experience low performance of the MS SQL Server, or when bad SQL memory settings were discovered during the pre-flight check of the upgrade, you can adjust the maximum memory settings for your SQL Server. 


Note: If you are not familiar with MS SQL Server, ask your SQL Server Administrator to complete the configuration steps. When you are using more than one SQL Server instance, don't use these steps. SolarWinds recommends that you recalculate the SQL Server memory yourself.

Product section

Network Performance Monitor

Resolution

Tip: If you do not want to calculate the precise maximum memory value, consider using the default value 2147483647 MB which is automatically configured by the SQL Server.

 

The calculation depends on the edition and version of your MS SQL Server.
 

  1. Review the edition of your SQL Server.

    MS SQL Server Express
    If you are running MS SQL Server Express, calculate the maximum memory as follows:
    SQL Server maximum memory = System memory in MB - 512 MB
    SQL Server Express edition has a limitation of 1024 MB (1 GB) of memory. If the resulting value is over 1024 MB (1 GB), use 1024 MB (1 GB) instead.  
     

    32-bit versions of MS SQL Server
    For 32-bit versions, use the same calculation as for MS SQL Express:

    SQL Server maximum memory = System memory in MB - 512 MB


    64-bit version of MS SQL Server
    Calculate the memory setting in the following formula:

    SQL Server maximum memory = System memory in MB - OS memory in MB


    OS memory depends on the System memory. To calculate OS memory, use the following formula:

    OS memory in MB = (((System memory in MB / 1024) * 64) + 1024)

    For System memory over 48 GB, use 4096 MB as the value for OS memory in MB.

      
  2. Set the value as the Maximum memory for the SQL Server.

  3. Restart the SQL Server to apply changes.

 

You should experience better performance of SQL Server, and the pre-flight check should no longer highlight any issue.