none
System.OutOfMemoryException Occurs on SQL Server 2008

    Question

  • Hello,

          My darabase server which is sql server 2008 Std. x64 edition throws a memory exception of System.OutOfMemoryException on following operations.

    1) when I execute an index script which rebuild my volume tables indexes.

    2) When I execute a Stotrd proc.

     

           Once this exception occurs It contimuesly appears on  other operations also. When I restart the whole server (OS) it get back to normal. But once this message appears all the activity is effected with this message.

    My memory is 8gb and I am consumis 7 GB

    I am using xeion quad core dual processor with Windows Server 20088 std x64

    any suggestions?

     

    Nilkanth Desai

     

          

    Tuesday, September 21, 2010 1:56 PM

Answers

  • Hi Nilkanth,

    Thanks for your post.

    It seems that SQL Server used too much memory, if 7GB does not include VAS Reservation (also called MemToLeave) which means SQL Server used more than 7GB physical memory and the operating system and other application only has less than 1 GB physical memory.

    I would recommend try the following:

    ·         Make sure that the latest service pack has been applied (SQL Server 2008 Service Pack 1);

    ·         The Minimum/Maximum server memory options have been set. For 8GB physical memory, you can set the minimum server memory to 2GB and maximum server memory to 6GB;

    ·         Run DBCC MEMORYSTATUS to monitor SQL Server Memory Usage according to http://support.microsoft.com/kb/271624;

    ·         Care should be taken if Lock Pages in Memory policy has been enabled, please refer to http://blogs.technet.com/b/askperf/archive/2008/03/25/lock-pages-in-memory-do-you-really-need-it.aspx;

    ·         Please run the Performance Monitor (PerfMon) to capture SQL Server working threads, you may need to add physical memory to the server if there much too much working threads and concurrent user connections.

    If the error still happens which may requires dump memory analysis and you’d better directly contact Microsoft CSS (http://support.microsoft.com).

    Hope this helps.

    Thanks,
    Chunsong


    --------------------------------------------------------------------------------
    Please remember to click "Mark as Answer" on the post that helps you, and to click "Unmark as Answer" if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

    Thursday, September 23, 2010 9:25 AM

All replies

  • Hello,

          My darabase server which is sql server 2008 Std. x64 edition throws a memory exception of System.OutOfMemoryException on following operations.

    1) when I execute an index script which rebuild my volume tables indexes.

    2) When I execute a Stotrd proc.

     

           Once this exception occurs It contimuesly appears on  other operations also. When I restart the whole server (OS) it get back to normal. But once this message appears all the activity is effected with this message.

    My memory is 8gb and I am consumis 7 GB

    I am using xeion quad core dual processor with Windows Server 20088 std x64

    any suggestions?

     

    Nilkanth Desai

     

          

    In addition to above when I start Management studio of SQL Server I receive forllowing exception.

    Description:
      Stopped working

    Problem signature:
      Problem Event Name: CLR20r3
      Problem Signature 01: ssms.exe
      Problem Signature 02: 2007.100.1600.22
      Problem Signature 03: 48753da6
      Problem Signature 04: System.Windows.Forms
      Problem Signature 05: 2.0.0.0
      Problem Signature 06: 4a275ebd
      Problem Signature 07: 16cf
      Problem Signature 08: 159
      Problem Signature 09: System.ComponentModel.Win32
      OS Version: 6.1.7600.2.0.0.272.7
      Locale ID: 1033

    Read our privacy statement online:
      http://go.microsoft.com/fwlink/?linkid=104288&clcid=0x0409

    If the online privacy statement is not available, please read our privacy statement offline:
      C:\Windows\system32\en-US\erofflps.txt

    Nilkanth Desai

     

    Tuesday, September 21, 2010 2:07 PM
  • Hello Nikanth,

    I suggest you first check if a service pack or updates is available for your both SQL Server and Windows OS. Apply whatever is applicable then check if the issue persists, and report back to us.


    Arthur My Blog
    By: TwitterButtons.com
    Tuesday, September 21, 2010 2:26 PM
  • Hi Nilkanth,

    Thanks for your post.

    It seems that SQL Server used too much memory, if 7GB does not include VAS Reservation (also called MemToLeave) which means SQL Server used more than 7GB physical memory and the operating system and other application only has less than 1 GB physical memory.

    I would recommend try the following:

    ·         Make sure that the latest service pack has been applied (SQL Server 2008 Service Pack 1);

    ·         The Minimum/Maximum server memory options have been set. For 8GB physical memory, you can set the minimum server memory to 2GB and maximum server memory to 6GB;

    ·         Run DBCC MEMORYSTATUS to monitor SQL Server Memory Usage according to http://support.microsoft.com/kb/271624;

    ·         Care should be taken if Lock Pages in Memory policy has been enabled, please refer to http://blogs.technet.com/b/askperf/archive/2008/03/25/lock-pages-in-memory-do-you-really-need-it.aspx;

    ·         Please run the Performance Monitor (PerfMon) to capture SQL Server working threads, you may need to add physical memory to the server if there much too much working threads and concurrent user connections.

    If the error still happens which may requires dump memory analysis and you’d better directly contact Microsoft CSS (http://support.microsoft.com).

    Hope this helps.

    Thanks,
    Chunsong


    --------------------------------------------------------------------------------
    Please remember to click "Mark as Answer" on the post that helps you, and to click "Unmark as Answer" if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

    Thursday, September 23, 2010 9:25 AM
  • You might want to use Results to File if your queries in SSMS return large resultsets. The error reported is a OOM condition experienced by SSMS. Ref: http://troubleshootingsql.wordpress.com/2010/08/22/system-outofmemoryexception-for-management-studio/
    This posting is provided "AS IS" with no warranties, and confers no rights.
    My Blog: http://troubleshootingsql.wordpress.com
    Twitter: @banerjeeamit
    SQL Server FAQ Blog on MSDN: http://blogs.msdn.com/sqlserverfaq
    Thursday, September 23, 2010 9:40 AM