<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">CSS SQL Server Engineers</title><subtitle type="html">This is the official team Web Log for Microsoft Customer Service and Support (CSS) SQL Support. Posts are provided by the CSS SQL Escalation Services team.</subtitle><id>http://blogs.msdn.com/psssql/atom.xml</id><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/default.aspx" /><link rel="self" type="application/atom+xml" href="http://blogs.msdn.com/psssql/atom.xml" /><generator uri="http://communityserver.org" version="2.1.61025.2">Community Server</generator><updated>2009-09-11T20:40:37Z</updated><entry><title>Unable to run SQL CLR procedure with System.Security.SecurityException</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/11/20/unable-to-run-sql-clr-procedure-with-system-security-securityexception.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/11/20/unable-to-run-sql-clr-procedure-with-system-security-securityexception.aspx</id><published>2009-11-20T22:03:00Z</published><updated>2009-11-20T22:03:00Z</updated><content type="html">&lt;P&gt;Recently, we have troubleshoot a customer issue related to SQL CLR.&amp;nbsp; The problem is that the assembly is configured to use external_access but he kept getting an exception similar to this (this is a sample call stack):&lt;/P&gt;&lt;FONT size=2&gt;
&lt;P&gt;&lt;/FONT&gt;Msg 6522, Level 16, State 1, Procedure sp_test, Line 0&lt;BR&gt;A .NET Framework error occurred during execution of user-defined routine or aggregate "sp_test": &lt;BR&gt;System.MethodAccessException: Test..ctor() ---&amp;gt; System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.&lt;BR&gt;System.Security.SecurityException: &lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Assembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Object assemblyOrString, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandle rmh, Object assemblyOrString, SecurityAction action, Boolean throwException)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Security.PermissionSetTriple.CheckSetDemand(PermissionSet demandSet, PermissionSet&amp;amp; alteredDemandset, RuntimeMethodHandle rmh)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Security.PermissionListSet.CheckSetDemand(PermissionSet pset, RuntimeMethodHandle rmh)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Security.PermissionListSet.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Threading.CompressedStack.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.Security.CodeAccessSecurityEngine.ReflectionTargetDemandHelper(Int32 permission, PermissionSet t&lt;BR&gt;&amp;nbsp;...&lt;BR&gt;System.MethodAccessException: &lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean&amp;amp; canBeCached, RuntimeMethodHandle&amp;amp; ctor, Boolean&amp;amp; bNeedSecurityCheck)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean fillCache)&lt;BR&gt;&amp;nbsp;&amp;nbsp; at System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache)&lt;BR&gt;&amp;nbsp; ...&lt;BR&gt;
&lt;P&gt;&lt;FONT color=#808080 size=2&gt;&lt;FONT color=#808080 size=2&gt;&lt;/P&gt;&lt;/FONT&gt;&lt;/FONT&gt;&amp;nbsp; 
&lt;P&gt;The issue turns out to be that customer has coded in a way that the object has a private constructor.&amp;nbsp;&amp;nbsp; They use third party code to dynamically create the type using Activator.CreateInstance.&amp;nbsp; This requires fully trusted code. &lt;A href="http://msdn.microsoft.com/en-us/library/he47tyc4.aspx"&gt;http://msdn.microsoft.com/en-us/library/he47tyc4.aspx&lt;/A&gt;&amp;nbsp;has documenation on this.&lt;/P&gt;
&lt;P&gt;From SQL CLR perspective, the solution is to use unsafe assembly or stop using private constructor.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;The following code will reproduce it if you set the assembly to be safe or external_access.&amp;nbsp; Unsafe will work.&lt;/P&gt;
&lt;P&gt;using System;&lt;BR&gt;using System.Data;&lt;BR&gt;using System.Data.SqlClient;&lt;BR&gt;using System.Data.SqlTypes;&lt;BR&gt;using Microsoft.SqlServer.Server;&lt;BR&gt;using System.Reflection;&lt;/P&gt;
&lt;P&gt;public partial class StoredProcedures&lt;BR&gt;{&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; [Microsoft.SqlServer.Server.SqlProcedure]&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; public static void sp_test()&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; object obj = Activator.CreateInstance(typeof(Test), true);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;public class Test&lt;BR&gt;{&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; private Test()&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR&gt;}&lt;/P&gt;
&lt;P&gt;};&lt;BR&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;-------------------------------------------------------------------------------------------------&lt;/P&gt;
&lt;P&gt;Jack Li | Senior Escalation Engineer | Microsoft SQL Server Support&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9926492" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="SQL CLR" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+CLR/default.aspx" /></entry><entry><title>SQL Server 2005 Cumulative Update or GDR fails when trying to rename the mssqlsystemresource files</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/11/20/sql-server-2005-cumulative-update-or-gdr-fails-when-trying-to-rename-the-mssqlsystemresource-files.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/11/20/sql-server-2005-cumulative-update-or-gdr-fails-when-trying-to-rename-the-mssqlsystemresource-files.aspx</id><published>2009-11-20T19:04:55Z</published><updated>2009-11-20T19:04:55Z</updated><content type="html">&lt;p&gt;I’ve seen a few customers run in to this recently when the resource database is in a different location than the master database.&amp;#160; A cumulate update or GDR for SQL Server 2005 may fail with the following for the SQL Server Database Services 2005 in the Summary_%.txt log file.&amp;#160; Look for the latest summary_%.txt file in the C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix folder.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&amp;#160;&lt;font size="2" face="Courier New"&gt;**********************************************************************************        &lt;br /&gt;Product Installation Status         &lt;br /&gt;Product&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; : SQL Server Database Services 2005 (MSSQLSERVER)         &lt;br /&gt;Product Version (Previous): 4035         &lt;br /&gt;Product Version (Final)&amp;#160;&amp;#160; :         &lt;br /&gt;Status&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; : Failure         &lt;br /&gt;Log File&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; : C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix\SQL9_Hotfix_KB970892_sqlrun_sql.msp.log         &lt;br /&gt;Error Number&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; : 29538         &lt;br /&gt;Error Description&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; : MSP Error: 29538&amp;#160; SQL Server Setup did not have the administrator permissions required to rename a file: E:\DATA\mssqlsystemresource1.ldf. To continue, verify that the file exists, and either grant administrator permissions to the account currently running Setup or log in with an administrator account. Then run SQL Server Setup again.         &lt;br /&gt;&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Note that the error indicates setup was not able to rename a file related to the system resource database.&amp;#160; If you bring up the referenced log file, this will give you more details about why this happened.&amp;#160; In this example the &lt;strong&gt;SQL9_Hotfix_KB970892_sqlrun_sql.msp.log&lt;/strong&gt; had the following additional information:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;font size="2" face="Courier New"&gt;Failed to copy file &amp;quot;E:\DATA\mssqlsystemresource.ldf&amp;quot; to &amp;quot;E:\DATA\mssqlsystemresource1.ldf&amp;quot;. Error 2        &lt;br /&gt;Failed to copy file &amp;quot;E:\DATA\mssqlsystemresource.mdf&amp;quot; to &amp;quot;E:\DATA\mssqlsystemresource1.mdf&amp;quot;. Error 2         &lt;br /&gt;Failed to copy file &amp;quot;E:\DATA\distmdl.ldf&amp;quot; to &amp;quot;E:\DATA\distmdl1.ldf&amp;quot;. Error 2         &lt;br /&gt;Failed to copy file &amp;quot;E:\DATA\distmdl.mdf&amp;quot; to &amp;quot;E:\DATA\distmdl1.mdf&amp;quot;. Error 2&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;In this case the actual error was Error 2, which is “The system cannot find the file specified.”&amp;#160; This will happen if system Resource database is in a different location than the master database.&amp;#160; To resolve, use the steps outlined in the topic “Moving System Databases” and the section titled “Moving the master and Resource Databases” &lt;a title="http://msdn.microsoft.com/en-us/library/ms345408(SQL.90).aspx" href="http://msdn.microsoft.com/en-us/library/ms345408(SQL.90).aspx"&gt;http://msdn.microsoft.com/en-us/library/ms345408(SQL.90).aspx&lt;/a&gt;.&lt;/p&gt;  &lt;ul&gt;   &lt;ul&gt;     &lt;li&gt;Since your master database is already in the desired location, you can start at step 7 in the “Moving the master and Resource Databases” section to finish up moving the Resource database to the same location as master. &lt;/li&gt;   &lt;/ul&gt; &lt;/ul&gt;  &lt;p&gt;For the distmdl related files, you can just create two empty(dummy) files from notepad and save them as &lt;strong&gt;distmdl.mdf&lt;/strong&gt; and &lt;strong&gt;distmdl.ldf&lt;/strong&gt; in the location that is referenced in the error message.&amp;#160; In this example, we created dummy &lt;strong&gt;E:\DATA\distmdl.ldf&lt;/strong&gt; and &lt;strong&gt;E:\DATA\distmdl.mdf&lt;/strong&gt;.&lt;/p&gt;  &lt;p&gt;&lt;font color="#808080" size="2" face="Calibri"&gt;Sarah Henwood | Microsoft SQL Server Escalation Services&lt;/font&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9926381" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Setup" scheme="http://blogs.msdn.com/psssql/archive/tags/Setup/default.aspx" /><category term="SQL 2005" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+2005/default.aspx" /><category term="Cumulative Update" scheme="http://blogs.msdn.com/psssql/archive/tags/Cumulative+Update/default.aspx" /></entry><entry><title>How It Works: Controlling SQL Server memory dumps</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/11/17/how-it-works-controlling-sql-server-memory-dumps.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/11/17/how-it-works-controlling-sql-server-memory-dumps.aspx</id><published>2009-11-17T21:35:16Z</published><updated>2009-11-17T21:35:16Z</updated><content type="html">&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: olive; font-size: 10pt; mso-bidi-font-size: 11.0pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;I just completed&lt;/font&gt; a lengthy bit of research and thought I would share it with everyone.&amp;#160;&amp;#160; There are several trace flags and registry keys outlined in this post.&amp;#160;&amp;#160;&amp;#160; &lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: olive; font-size: 10pt; mso-bidi-font-size: 11.0pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi"&gt;     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: olive; font-size: 10pt; mso-bidi-font-size: 11.0pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi"&gt;     &lt;p&gt;&lt;font color="#ff0000"&gt;!!! As always USE WITH APPROPRIATE CAUTION !!!&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: olive; font-size: 10pt; mso-bidi-font-size: 11.0pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt; mso-fareast-font-family: &amp;#39;Times New Roman&amp;#39;"&gt;&lt;font color="#000000"&gt;From:&lt;/font&gt;&lt;/span&gt;&lt;/b&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt; mso-fareast-font-family: &amp;#39;Times New Roman&amp;#39;"&gt;&lt;font color="#000000"&gt; Robert Dorr        &lt;br /&gt;&lt;b&gt;Sent:&lt;/b&gt; Tuesday, November 17, 2009 3:23 PM        &lt;br /&gt;&lt;b&gt;Subject:&lt;/b&gt; RE: SQL Server 2008 Trace Flag        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;   &lt;p&gt;&lt;font color="#000000" size="3" face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;It is a dump trigger that is enabled for error 5243.&amp;#160;&amp;#160; (You usually do this with dbcc dumptrigger(‘set’, 5243) or –y5243 on the command line)       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;However, 5243 is a special error in that it is automatically setup to capture a dump.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220ce290 00000000`020817bf sqlservr!stackTraceCallBack+0x49 [e:\sql10_katmai_t\sql\ntdbms\storeng\dfs\startup\stack.cpp @ 4972]       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220ce2d0 00000000`013a3d41 sqlservr!ex_raise2+0xcdd8bf       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220ce630 00000000`02deb8ce sqlservr!ex_raise+0x51 [e:\sql10_katmai_t\sql\common\dk\sos\src\sosexcept.cpp @ 1258]       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220ce6c0 00000000`01e860fc &lt;span style="background: yellow; mso-highlight: yellow"&gt;sqlservr!RaiseInconsistencyError&lt;/span&gt;+0x33e [e:\sql10_katmai_t\sql\ntdbms\storeng\drs\record.cpp @ 1006]        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220ce9c0 00000000`0158b06d sqlservr!PageRef::Fix+0xe6157c       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220cea30 00000000`02a71cfb &lt;span style="background: yellow; mso-highlight: yellow"&gt;sqlservr!IAMPageRef::Fix&lt;/span&gt;+0x1d [e:\sql10_katmai_t\sql\ntdbms\storeng\include\allocpageref.h @ 185]        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220cea70 00000000`02cc0623 &lt;span style="background: yellow; mso-highlight: yellow"&gt;sqlservr!DeferredAllocUnitDrop::DeAllocateFirstIAMAndItsExtents&lt;/span&gt;+0x23b [e:\sql10_katmai_t\sql\ntdbms\storeng\dfs\alloc\dealloc.cpp @ 914]        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;00000000`220cebe0 00000000`03404ede sqlservr!DeferredAllocUnitDrop::ProcessOneIAM+0xa3 [e:\sql10_katmai_t\sql\ntdbms\storeng\dfs\alloc\dealloc.cpp @ 1078]       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;In this case it is a background task that wakes up and is attempting to deallocate and encountering the damaged ‘so called’ IAM page.&amp;#160;&amp;#160;&amp;#160; I suspect it is like Paul mentioned that the pointer in the sysallocunits was some-how damaged or the IAM chain was damaged.&amp;#160;&amp;#160;&amp;#160; The IAM page was re-used or the chain pointer was bad to the back-ground task keeps trying to access the IAM to deallocate and it can’t.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;For this specific issue we might have been able to disable deferred deallocation but you would have to know that.&amp;#160; (-T670)       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The error 5243 is an automatic dump trigger setup for corruption capture that you can’t control with dbcc dumptrigger(‘clear’, 5243)        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The –T2558 is not to disable all dumps it disables DBCC CHECKDB Watson integration and since you were not hitting CHECKDB errors in this code it won’t change things.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;You can generically use –T2542 (skip mini-dump)       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Trace flag –T3656 disables loading of dbghelp so the stack should not be put in the error log if this is enabled       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The dump logic also has some limitations in that if you had had full or filtered dumps enabled it will only take ## before it downgrades to mini-dump only as well.&amp;#160; (See registry section below)       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Worse come to worse you could have renamed SQLDumper.exe for a bit until the problem was corrected.&amp;#160;&amp;#160; This would prevent .mdmp’s but not the error log growth.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;If error is severity 20 or higher the dump is automatically generated.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Trace flag –T8026 tells dump trigger to remove the trigger after the first dump has been triggered.&amp;#160; (Does not disable the automatic triggers)       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;If you enable trace flag –T3628 it can include other errors based on a severity.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.5in; mso-list: l0 level1 lfo1" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;If you enable trace flag –T3629 it will include messages marked to include with this trace flag enabled.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Automatic Dumping Control           &lt;p&gt;&lt;/p&gt;         &lt;/font&gt;&lt;/span&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;A bunch of the automatic, message dumping information is controlled by the message formatting specifications.&amp;#160;&amp;#160; When combined with some of the trace flags I just outlined you can determine the behaviors.&amp;#160; This information is contained in an internal array returning if the message should always log, always dump, or dump only if trace flag 3629 is enabled.&amp;#160;&amp;#160;&amp;#160; The array is generated from a header file so it is not just something I can pull up and show you easily.&amp;#160; It is actually part of the build that takes a header, parses comments and generates the array.&amp;#160;&amp;#160; &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Here are some of the errors that are setup to dump.&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;ErrorGenerateDump: Always&lt;span style="color: #003300; font-size: 10pt"&gt;           &lt;p&gt;&lt;/p&gt;         &lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;   &lt;table style="margin: auto auto auto 0.5in; border-collapse: collapse; mso-yfti-tbllook: 1184; mso-padding-alt: 0in 0in 0in 0in" class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;       &lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 85.1pt; padding-right: 5.4pt; border-top: black 1pt solid; border-right: black 1pt solid; padding-top: 0in" valign="top" width="113"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;5243&lt;span style="color: #003300; font-size: 10pt"&gt;                     &lt;p&gt;&lt;/p&gt;                   &lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;         &lt;/td&gt;       &lt;/tr&gt;        &lt;tr style="mso-yfti-irow: 1"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 85.1pt; padding-right: 5.4pt; border-top: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="113"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;5242&lt;span style="color: #003300; font-size: 10pt"&gt;                     &lt;p&gt;&lt;/p&gt;                   &lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;         &lt;/td&gt;       &lt;/tr&gt;        &lt;tr style="mso-yfti-irow: 2"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 85.1pt; padding-right: 5.4pt; border-top: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="113"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;8624                 &lt;p&gt;&lt;/p&gt;               &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;         &lt;/td&gt;       &lt;/tr&gt;        &lt;tr style="mso-yfti-irow: 3"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 85.1pt; padding-right: 5.4pt; border-top: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="113"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;8644                 &lt;p&gt;&lt;/p&gt;               &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;         &lt;/td&gt;       &lt;/tr&gt;        &lt;tr style="mso-yfti-irow: 4"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 85.1pt; padding-right: 5.4pt; border-top: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="113"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;8930                 &lt;p&gt;&lt;/p&gt;               &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;         &lt;/td&gt;       &lt;/tr&gt;        &lt;tr style="mso-yfti-irow: 5"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 85.1pt; padding-right: 5.4pt; border-top: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="113"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;8967                 &lt;p&gt;&lt;/p&gt;               &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;         &lt;/td&gt;       &lt;/tr&gt;        &lt;tr style="mso-yfti-irow: 6; mso-yfti-lastrow: yes"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 85.1pt; padding-right: 5.4pt; border-top: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="113"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;9239                 &lt;p&gt;&lt;/p&gt;               &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;         &lt;/td&gt;       &lt;/tr&gt;     &lt;/tbody&gt;&lt;/table&gt; &lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Registry           &lt;p&gt;&lt;/p&gt;         &lt;/font&gt;&lt;/span&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;There are some registry keys to set the dump limits as well.&amp;#160; By default it is set to (0) indicating INFINITE.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 12pt 0.25in" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Under the Setup base key location:&amp;#160;&amp;#160; (EX:&amp;#160; HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL10.SQL2008\Setup)       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.75in; mso-list: l1 level1 lfo2" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;MaxDumps (DWORD) value       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.75in; mso-list: l1 level1 lfo2" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;MaxFullDumps (DWORD) value       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="text-indent: -0.25in; margin: 0in 0in 0pt 0.75in; mso-list: l1 level1 lfo2" class="MsoListParagraph"&gt;&lt;span style="font-family: symbol; color: #003300; font-size: 10pt; mso-bidi-font-family: symbol; mso-fareast-font-family: symbol"&gt;&lt;span style="mso-list: ignore"&gt;·&lt;span style="font: 7pt &amp;quot;Times New Roman&amp;quot;"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;SQLExceptionDumpPath&amp;#160; (String) value&lt;span style="color: #003300; font-size: 10pt"&gt;           &lt;p&gt;&lt;/p&gt;         &lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Display Dump Triggers           &lt;p&gt;&lt;/p&gt;         &lt;/font&gt;&lt;/span&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;You can use dbcc dumptrigger(‘display’) to see the currently installed dump triggers on the system.&amp;#160;&amp;#160; We sure to enabled dbcc tracon(3604) to retrieve the output of the command.       &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;------------------------------------------------------------------------&lt;/font&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;From:&lt;/font&gt;&lt;/span&gt;&lt;/b&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt; Paul Randal (Sysolutions Inc.)        &lt;br /&gt;&lt;b&gt;Sent:&lt;/b&gt; Tuesday, November 17, 2009 11:04 AM        &lt;br /&gt;&lt;b&gt;Subject:&lt;/b&gt; RE: SQL Server 2008 Trace Flag        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;   &lt;p&gt;&lt;font color="#000000" size="3" face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;That’s an allocation unit that doesn’t have a link to it in sysallocunits – repair should have deleted the IAM chain. Is it the same IAM chain in the subsequent 2576?     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;The 5243s in the dump/log are usually from record corruption (can’t see exactly where it’s throwing the error as I don’t have source code access any more) – Bob?     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;From the frequency, I’m guessing it’s a record in a system table.     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Paul S. Randal     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Managing Director, &lt;a href="http://www.sqlskills.com/"&gt;&lt;u&gt;&lt;font color="#0000ff"&gt;SQLskills.com&lt;/font&gt;&lt;/u&gt;&lt;/a&gt;      &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Microsoft Regional Director / SQL MVP     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;&lt;a href="http://www.sqlskills.com/blogs/paul"&gt;&lt;u&gt;&lt;font color="#0000ff"&gt;http://www.sqlskills.com/blogs/paul&lt;/font&gt;&lt;/u&gt;&lt;/a&gt; | &lt;a href="http://twitter.com/PaulRandal"&gt;&lt;u&gt;&lt;font color="#0000ff"&gt;http://twitter.com/PaulRandal&lt;/font&gt;&lt;/u&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style="color: #1f497d"&gt;     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;         &lt;p&gt;&lt;font face="Calibri"&gt;------------------------------------------------------------------------&lt;/font&gt;&lt;/p&gt;       &lt;/span&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&lt;b&gt;Sent:&lt;/b&gt; Tuesday, November 17, 2009 8:49 AM        &lt;br /&gt;&lt;b&gt;To:&lt;/b&gt; Paul Randal (Sysolutions Inc.); Robert Dorr        &lt;br /&gt;&lt;b&gt;Subject:&lt;/b&gt; RE: SQL Server 2008 Trace Flag        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;   &lt;p&gt;&lt;font color="#000000" size="3" face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Hi Paul and Robert,     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Glad to have your help. Attachment are error log, one dump file, and one DBCC CHECKDB output. I’m in China so the DBCC output is Chinese. And in English it reads:     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;-----------------------------------------------------------------------------     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Server: Msg 8906, Level 16, State 1, Line 1     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Page (1:5882160) in database ID 8 is allocated in the SGAM (1:5623553) and PFS (1:5879976), but was not allocated in any IAM. PFS flags 'MIXED_EXT ALLOCATED 0_PCT_FULL'.     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Msg 2576, Level 16, State 1, Line 1      &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;The Index Allocation Map (IAM) page (0:0) is pointed to by the previous pointer of IAM page (1:5882163) in object ID 0, index ID -1, partition ID 0, alloc unit ID 72057599386320896 (type Unknown), but it was not detected in the scan.     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;-------------------------------------------------------------------------------     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Then I run DBCC CHECKDB with ALLOW_DATA_LOSS again, there is no more&amp;#160; Msg 8906 and&amp;#160; Msg 2576.     &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;Then I run DBCC CHECKDB to double check, no Msg 8906 but one Msg 2576.&lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt; &lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: #1f497d; font-size: 10pt"&gt;   &lt;p&gt;     &lt;p&gt;&lt;font face="Calibri"&gt;&lt;span style="font-family: &amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;; color: #a6a6a6; font-size: 8pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi; mso-fareast-font-family: &amp;#39;Times New Roman&amp;#39;; mso-fareast-theme-font: minor-fareast; mso-ansi-language: en-us; mso-fareast-language: en-us; mso-bidi-language: ar-sa; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-no-proof: yes"&gt;Bob Dorr - Principal SQL Server Escalation Engineer&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;   &lt;/p&gt; &lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9923876" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Tools" scheme="http://blogs.msdn.com/psssql/archive/tags/Tools/default.aspx" /><category term="How It Works" scheme="http://blogs.msdn.com/psssql/archive/tags/How+It+Works/default.aspx" /><category term="SQL Server 2008" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2008/default.aspx" /></entry><entry><title>How It Works: How many databases can be backed up simultaneously?</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/11/13/how-it-works-how-many-databases-can-be-backed-up-simultaneously.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/11/13/how-it-works-how-many-databases-can-be-backed-up-simultaneously.aspx</id><published>2009-11-13T17:02:52Z</published><updated>2009-11-13T17:02:52Z</updated><content type="html">&lt;p&gt;Previously I have posted details on backup/restore designs and how to tell what backup/restore is doing.&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a href="http://blogs.msdn.com/psssql/archive/2009/03/03/how-it-works-sql-server-vdi-vss-backup-resources.aspx"&gt;http://blogs.msdn.com/psssql/archive/2009/03/03/how-it-works-sql-server-vdi-vss-backup-resources.aspx&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://blogs.msdn.com/psssql/archive/2008/01/28/how-it-works-sql-server-backup-buffer-exchange-a-vdi-focus.aspx"&gt;http://blogs.msdn.com/psssql/archive/2008/01/28/how-it-works-sql-server-backup-buffer-exchange-a-vdi-focus.aspx&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://blogs.msdn.com/psssql/archive/2008/01/23/how-it-works-what-is-restore-backup-doing.aspx"&gt;http://blogs.msdn.com/psssql/archive/2008/01/23/how-it-works-what-is-restore-backup-doing.aspx&lt;/a&gt;&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;This post attempts to bring the concepts together to answer the question: &lt;em&gt; &amp;quot;How many databases can be backed up simultaneously?&amp;quot;&lt;/em&gt;&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/HowItWorksHowmanydatabasescanbebackedups_95F1/image_2.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/HowItWorksHowmanydatabasescanbebackedups_95F1/image_thumb.png" width="595" height="292" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;The figure should look familiar as a combination of the previous posts.&amp;#160;&amp;#160;&amp;#160; The reason I have repeated it is to remind us all of the entities involved.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;Entity: Worker Pool&amp;#160;&amp;#160; &lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;The controller and database worker come from the worker pool.&amp;#160; So if your max worker thread is configured for 255 the answer would be a max of 255 / 2 = 127 databases.&amp;#160;&amp;#160;&amp;#160; You probably won't get to 127 with this configuration as you have system workers (lazy writer, checkpoint, log writer, and others) that already are using workers.&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;Entity: Memory&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;The backup buffers are allocated outside the buffer pool memory so the remaining virtual address space must be considered.&amp;#160;&amp;#160; For example on a 32 bit system you get into the 'memory to leave' discussion.&amp;#160;&amp;#160; On 64 bit it is not a 'memory to leave' discussion but how much you shrink the buffer pool memory to support allocations outside the buffer pool.&amp;#160; The direct memory consumers to consider are:&lt;/p&gt;    &lt;ul&gt;     &lt;li&gt;The stream threads (one per output target) are threads so the stacks are allocated by the operating system outside the buffer pool.&amp;#160; (x86 = .5MB, x86 WOW = .75MB, x64 = 2MB, …)&lt;/li&gt;      &lt;li&gt;The backup buffers are larger than 8K so they are also allocated outside the buffer pool.&amp;#160; See previous posts to determine the selected buffer sizes.&lt;/li&gt;      &lt;li&gt;When you add VDI into the picture the VDI providers memory is also allocated outside the buffer pool.&amp;#160; The VDI provider can tell you the memory requirements.&lt;/li&gt;   &lt;/ul&gt; &lt;/blockquote&gt;  &lt;p&gt;The answer to the question becomes an exercise in looking at both of these key entities to determine how many of operations you can accommodate on the specific system.&lt;/p&gt;  &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;span style="font-family: &amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;; color: #a6a6a6; font-size: 8pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi; mso-ansi-language: en-us; mso-fareast-font-family: &amp;#39;Times New Roman&amp;#39;; mso-fareast-theme-font: minor-fareast; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-fareast-language: en-us; mso-bidi-language: ar-sa; mso-no-proof: yes"&gt;Bob Dorr - Principal SQL Server Escalation Engineer&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9922054" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="How It Works" scheme="http://blogs.msdn.com/psssql/archive/tags/How+It+Works/default.aspx" /><category term="2008" scheme="http://blogs.msdn.com/psssql/archive/tags/2008/default.aspx" /><category term="2005" scheme="http://blogs.msdn.com/psssql/archive/tags/2005/default.aspx" /><category term="SQL 2005" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+2005/default.aspx" /></entry><entry><title>The SQL Server Wait Type Repository…</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/11/03/the-sql-server-wait-type-repository.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/11/03/the-sql-server-wait-type-repository.aspx</id><published>2009-11-03T05:56:38Z</published><updated>2009-11-03T05:56:38Z</updated><content type="html">&lt;p&gt;As part of my talk at the 2009 US PASS Summit here in Seattle called &lt;strong&gt;Inside SQL Server Wait Types&lt;/strong&gt;, I’m creating this blog post as a reference point that can be used to find out information about wait types in SQL Server 2005 and 2008.&amp;#160; My hope is that if you have a question about a wait type you encounter with SQL Server 2005, 2008, or beyond, you will use this blog post as the starting point. This blog post should also be used as an enhancement to what you can find at the following SQL Server Books Online topic:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ms179984.aspx"&gt;sys.dm_os_wait_stats (Transact-SQL)&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Why use this blog post over other references? Because information in this blog post will be based on the the actual product source code and empirical testing of scenarios that cause these wait types.&lt;/p&gt;  &lt;p&gt;This page is under construction but will contain the following types of information:&lt;/p&gt;  &lt;p&gt;1) Table of all wait types as listed in sys.dm_os_wait_stats.&lt;/p&gt;  &lt;p&gt;This table will contain the following types of information:&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;types organized by categories &lt;/li&gt;    &lt;li&gt;Which types apply to SQL 2005, SQL 2008, or both &lt;/li&gt;    &lt;li&gt;More descriptions for how you might encounter these &lt;/li&gt;    &lt;li&gt;Tips on what to do (if anything) &lt;/li&gt;    &lt;li&gt;List of specific types that can be safely ignored &lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;2) Links to details on some wait types&lt;/p&gt;  &lt;p&gt;Some of these types deserve special treatment so we will provide links to more detailed scenarios for certain types including other blog posts, posts on this blog, whitepapers, etc&lt;/p&gt;  &lt;p&gt;This include more details on how you can use various tools to see waits such as DMVs, Extended Events, Management Data Warehouse, Activity Monitor, and Performance Counters.&lt;/p&gt;  &lt;p&gt;3) Other References on the topic&lt;/p&gt;  &lt;p&gt;I want this blog post to be a living document and help feed enhancements to the SQL Server Books Online. So if you encounter a question on a wait type that is confusing or not listed in this post, please post a comment to this blog post or email &lt;a href="mailto:psssql@microsoft.com"&gt;psssql@microsoft.com&lt;/a&gt;. This isn’t to obtain “free support” for a problem but to be used to help enhance and create the right content for the community on this topic.&lt;/p&gt;  &lt;p&gt;Look for the expansion of this blog post with these details in the next 3-4 weeks following the PASS conference.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Bob Ward    &lt;br /&gt;Microsoft&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9916580" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Extended Events" scheme="http://blogs.msdn.com/psssql/archive/tags/Extended+Events/default.aspx" /><category term="SQL Server 2008" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2008/default.aspx" /><category term="PASS 2009" scheme="http://blogs.msdn.com/psssql/archive/tags/PASS+2009/default.aspx" /><category term="Wait Types" scheme="http://blogs.msdn.com/psssql/archive/tags/Wait+Types/default.aspx" /></entry><entry><title>Reduce locking and other needs when updating data - Better Performance</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/10/26/reduce-locking-and-other-needs-when-updating-data-better-performance.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/10/26/reduce-locking-and-other-needs-when-updating-data-better-performance.aspx</id><published>2009-10-26T16:35:29Z</published><updated>2009-10-26T16:35:29Z</updated><content type="html">&lt;p&gt;The following pattern typically stems from an old practice used in SQL 4.x and 6.x days, before IDENTITY was introduced.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;begin tran      &lt;br /&gt;declare @iVal int&lt;/p&gt;    &lt;p&gt;select @iVal = iVal from CounterTable (HOLDLOCK) where CounterName = 'CaseNumber'&lt;/p&gt;    &lt;p&gt;update CounterTable      &lt;br /&gt;set iVal = @iVal + 1       &lt;br /&gt;where CounterName = 'CaseNumber'&lt;/p&gt;    &lt;p&gt;commit tran&lt;/p&gt;    &lt;p&gt;return @iVal&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;This can be a dangerous construct.&amp;#160; Assume that the query is cancelled (attention) right after the select.&amp;#160; SQL Server treats this as a batch termination and does not execute other statements.&amp;#160;&amp;#160; The application now holds a lock under the open transaction and without proper handling it leads to blocking.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;One Statement Fix&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;declare @iVal int&lt;/p&gt;    &lt;p&gt;update CounterTable      &lt;br /&gt;&lt;font color="#008000"&gt;&lt;strong&gt;set @iVal = iVal = iVal + 1&lt;/strong&gt;         &lt;br /&gt;&lt;/font&gt;where CounterName = 'CaseNumber'&lt;/p&gt;    &lt;p&gt;return @iVal&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;SQL Server allows you to update a value and return the updated value into a variable.&amp;#160;&amp;#160; A single update statement can do all the work.&amp;#160;&amp;#160; If the query is cancelled by the application the update is atomic and will complete or rollback but the application has much better control over the lock and transaction scope.&lt;/p&gt;  &lt;p&gt;Use this to help reduce blocking and possible deadlock issues.&amp;#160;&amp;#160; Since the lookup only takes place one time it can also increase performance of you application.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;&lt;font size="4"&gt;[OCT 28, 2009] - Update&lt;/font&gt;&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;One of the great things about the blog is that I get to interact with other bright individuals.&amp;#160;&amp;#160; From this blog I received feedback from our SQL MVP community and they pointed out some things.&lt;/p&gt;  &lt;p&gt;The goals of my original post were:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;1.&amp;#160;&amp;#160; Point out the issue with bad application design leaving transaction open and holding locks&lt;/p&gt;    &lt;p&gt;2.&amp;#160;&amp;#160; Point out that the locking behavior can result in unexpected deadlocks&lt;/p&gt;    &lt;p&gt;3.&amp;#160;&amp;#160; Point out a simple way to avoid the issue.&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;The scenario I presented is limited to areas where you have appropriate primary keys that prevent updated from occurring in a way you might not expect.&amp;#160; The following blog posts points out some of the pitfalls that things like HOLDLOCK and concurrent insert statements can encounter as well.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 11pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi; mso-ansi-language: en-us; mso-fareast-font-family: calibri; mso-fareast-theme-font: minor-latin; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-fareast-language: en-us; mso-bidi-language: ar-sa"&gt;&lt;a href="http://sqlblogcasts.com/blogs/tonyrogerson/archive/2006/06/30/855.aspx"&gt;&lt;u&gt;&lt;font color="#800080"&gt;http://sqlblogcasts.com/blogs/tonyrogerson/archive/2006/06/30/855.aspx&lt;/font&gt;&lt;/u&gt;&lt;/a&gt;&lt;/span&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;This lead to the following discussion (reduced for the blog post).&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;----- SQL MVP Message-----&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;The sp_getapplock is a no brainer for me - its application &amp;quot;tables&amp;quot; independent so does not lock out read only queries which is what happens if you use UPDLOCK, HOLDLOCK is horrible and causes deadlocks, other methods require SERIALIZABLE which again leads to deadlocks.&lt;/font&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;Orphaned transactions should never happen because it should be done in a succinct stored procedure, leaving the xact open would be a programming error.&lt;/font&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;[RDORR]&amp;#160; This is not always true, if the logic is wrapped in a stored procedure it still does not prevent the query timeout case.&amp;#160;&amp;#160; The example below shows how you can still have a transaction open after the procedure is cancelled from the client and you don't get a warning about the transaction count being different on entry and exit of the procedure.&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt; &lt;font color="#000000" size="2" face="Courier New"&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;       &lt;blockquote&gt;         &lt;p&gt;use&lt;/p&gt;          &lt;p&gt;&lt;font size="2"&gt;tempdb&lt;/font&gt;&lt;/p&gt;         &lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;            &lt;p&gt;go&lt;/p&gt;            &lt;p&gt;select&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;           &lt;font size="2"&gt;&lt;/font&gt;&lt;font color="#ff00ff" size="2"&gt;&lt;font color="#ff00ff" size="2"&gt;@@TRANCOUNT&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;            &lt;p&gt;go&lt;/p&gt;            &lt;p&gt;create&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;           &lt;font size="2"&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;procedure&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; spTest&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;            &lt;p&gt;as&lt;/p&gt;            &lt;p&gt;begin&lt;/p&gt;         &lt;/font&gt;&lt;/blockquote&gt;       &lt;font size="2"&gt;         &lt;p&gt;&lt;/p&gt;          &lt;p&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;begin&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;tran&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;         &lt;font size="2"&gt; &lt;/font&gt;          &lt;p&gt;&lt;/p&gt;          &lt;p&gt;&lt;/p&gt;          &lt;p&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;waitfor&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;delay&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;&lt;font color="#ff0000" size="2"&gt;'01:00:00'&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;         &lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;            &lt;p&gt;end&lt;/p&gt;            &lt;p&gt;go&lt;/p&gt;            &lt;p&gt;exec&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;           &lt;font size="2"&gt;spTest&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;&lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;-- Cancel execution of this with a query timeout (attention)&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt; &lt;/font&gt;            &lt;p&gt;go&lt;/p&gt;            &lt;p&gt;select&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;           &lt;font size="2"&gt;&lt;/font&gt;&lt;font color="#ff00ff" size="2"&gt;&lt;font color="#ff00ff" size="2"&gt;@@TRANCOUNT&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;-- still == 1&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt; &lt;/font&gt;      &lt;p&gt;&lt;font size="2"&gt;&lt;font color="#ff0000" size="2"&gt;&lt;strong&gt;NOTE:&amp;#160; You still need logic in the application (like all should have) to handle activity after a cancel request to reset the proper state.&lt;/strong&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;   &lt;/font&gt;    &lt;p&gt;&lt;/p&gt;   &lt;font color="#000000" size="2" face="Courier New"&gt;Ok - the begin / try; yep - that would work; however - you will require more complex logic to do the re-try; if you have gone the UPDLOCK, HOLDLOCK methods and have used begin try then the transaction you are in can only be rolled back so you are a bit stuck there too.&lt;/font&gt;&lt;/font&gt;   &lt;blockquote&gt;   &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;/p&gt;    &lt;p&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;[RDORR]&amp;#160; I am saying you do the insert and not the select.&amp;#160;&amp;#160; If the insert succeeds (you have proper PK of course) then there was not a row.&amp;#160; If it fails then there was a row.&amp;#160;&amp;#160; This only requires a single lookup in the table and you can handle the @@ERROR condition.&lt;/font&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;I had a recent client who had the orphaned transaction problem that caused massive blocking - they had no trapping in place, this one was SQL 2000 so I got them to write something around sysprocesses; in 2005 and 2008 you can use the BLOCKED_PROCESS_REPORT - you could write into the activation stored proc on the event notifications queue to pick that specific event type up and if caused by a specific statement/process then actually issue a KILL&lt;span style="mso-spacerun: yes"&gt;&amp;#160; &lt;/span&gt;- that make sense? It's application dependent though and I tend to go with the on BLOCKED_PROCESS_REPORT (raised because the threshold in sp_configure is set to 5 seconds) just email me and let me deal with it...&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;/p&gt;  &lt;p&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;-----RDORR Message-----&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;Devil's Advocate:&lt;span style="mso-spacerun: yes"&gt;&amp;#160; &lt;/span&gt;Why would you not have a PK on the table and just try the insert.&lt;span style="mso-spacerun: yes"&gt;&amp;#160;&amp;#160; &lt;/span&gt;Use Try/Catch to eat the PK violation so you don't need all the locking?&lt;span style="mso-spacerun: yes"&gt;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;I assume this is a simple sample and you want to gather other data and it is not this simple?&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;/p&gt;  &lt;p&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;What would you suggest to the user about the attention problem?&lt;span style="mso-spacerun: yes"&gt;&amp;#160; &lt;/span&gt;We see customers get into trouble that after they acquire the lock (say app lock in your scenario) an attention hits and they don't issue a rollback and such.&lt;span style="mso-spacerun: yes"&gt;&amp;#160;&amp;#160; &lt;/span&gt;So they now lock up everything.&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;/p&gt;  &lt;p&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;-----SQL MVP Message-----&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;It's not really a good method for doing this because you can still get repeated values (see my blog: &lt;/font&gt;&lt;a href="http://sqlblogcasts.com/blogs/tonyrogerson/archive/2006/06/30/855.aspx"&gt;&lt;u&gt;&lt;font color="#800080" size="2" face="Courier New"&gt;http://sqlblogcasts.com/blogs/tonyrogerson/archive/2006/06/30/855.aspx&lt;/font&gt;&lt;/u&gt;&lt;/a&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;) which uses sp_getapplock instead as an alternate approach.&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;/p&gt;  &lt;p&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;The problem is that unless you literally have a straigh UPDATE and WHERE without any other table references then the SELECT side of the UPDATE is done before applying the locks to then do the update so the locking goes a bit mad.&lt;/font&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoPlainText"&gt;&lt;/p&gt;  &lt;p&gt;&lt;font color="#000000" size="2" face="Courier New"&gt;I think the answer you need to state that you must have a unique constraint so that you are only ever updating one row and can guarantee that - also you need to do if @@rowcount &amp;gt; 1 then raiserror; also that you should not use sub queries and other table references....&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;font face="Calibri"&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;span style="font-family: &amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;; color: #a6a6a6; font-size: 8pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi; mso-ansi-language: en-us; mso-fareast-font-family: &amp;#39;Times New Roman&amp;#39;; mso-fareast-theme-font: minor-fareast; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-fareast-language: en-us; mso-bidi-language: ar-sa; mso-no-proof: yes"&gt;Bob Dorr - Principal SQL Server Escalation Engineer&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9913016" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Engine" scheme="http://blogs.msdn.com/psssql/archive/tags/Engine/default.aspx" /><category term="Troubleshooting: The DB Engine" scheme="http://blogs.msdn.com/psssql/archive/tags/Troubleshooting_3A00_+The+DB+Engine/default.aspx" /><category term="SQL Server 2008" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2008/default.aspx" /><category term="2008" scheme="http://blogs.msdn.com/psssql/archive/tags/2008/default.aspx" /><category term="SQL 2005" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+2005/default.aspx" /></entry><entry><title>Should I have a SNAC with my cumulative update?</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/10/23/should-i-have-a-snac-with-my-cumulative-update.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/10/23/should-i-have-a-snac-with-my-cumulative-update.aspx</id><published>2009-10-23T15:26:41Z</published><updated>2009-10-23T15:26:41Z</updated><content type="html">&lt;p&gt;Here is a question we have received from several customers and internally at Microsoft:&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Do I need to apply the “SNAC” package that comes with some of the cumulative updates?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Just so we are all on the same terms, SNAC refers to &lt;a href="http://msdn.microsoft.com/en-us/data/aa937733.aspx"&gt;SQL Native Client&lt;/a&gt;. and basically contains our SQL Server “native code” data providers including OLE-DB and ODBC.&lt;/p&gt;  &lt;p&gt;To understand more why people have asked this question, let’s look at a Cumulative Update 4 for SQL Server 2008 SP1 as found at: &lt;a title="http://support.microsoft.com/kb/973602" href="http://support.microsoft.com/kb/973602"&gt;http://support.microsoft.com/kb/973602&lt;/a&gt; as an example. Please note that there are some differences for SQL Server 2005 which I’ll talk about later in the blog post.&lt;/p&gt;  &lt;p&gt;When you select &lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_2.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_thumb.png" width="244" height="68" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;you are presented with the following choices (by default we detect your OS platform and present you with only packages that apply, but you can expand to get all platform packages):&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_6.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_thumb_2.png" width="776" height="329" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;The first package titled SQL_Server_2008_SP1_Cumulative_Update_4 is the “main” CU package you would install on a server or client with SQL Server components. The package I’ve highlighted is referred to as the “SNAC package”. So when presented with this screen you may be asking “Do I need to apply this separate package?” (there are other packages listed here and I’ll talk about them as well later in this blog post).&lt;/p&gt;  &lt;p&gt;The answer is “it depends” (don’t you hate it when people say this). Consider these two scenarios:&lt;/p&gt;  &lt;p&gt;1) You have SQL Server installed on a server or client tools installed on a client computer&lt;/p&gt;  &lt;p&gt;The answer is NO because if you install the “main” cumulative update package you get the bits that come in the SNAC package. You may wonder why it matters whether SNAC is updated on the server itself especially if you don’t run any applications on your server that use SNAC. Linked Server Queries are one of the big reasons. A “default” SQL Server linked server is based on SNAC so this DLL (sqlncli.dll for 2005 and sqlncli10.dll for 2008) will be loaded in SQLSERVR.EXE to run a linked server query.&lt;/p&gt;  &lt;p&gt;2) You don’t have SQL Server installed on a client or server but have an application that uses SNAC&lt;/p&gt;  &lt;p&gt;The answer is YES. In fact, that is why we created a separate SNAC package. For customers who just need the SNAC update but don’t want to download and install the entire main CU package.&lt;/p&gt;  &lt;p&gt;What would happen if you did try to install the main CU package on a machine where SQL Server is not installed but SNAC was installed? The answer is nothing more than if you had just installed the SNAC package (except the SQL Setup Support Files get installed). We detect what is already installed and only offer up to you the appropriate updates. In the case of a machine where SNAC is the only thing installed, you would see a screen like this from the main CU:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_18.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_thumb_8.png" width="806" height="705" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;the feature that shows up is just called “Shared Features”. If you proceed with the rest of the install, it will only update sqlncl10.dll to the version with the cumulative update.&lt;/p&gt;  &lt;p&gt;Why did we ship a separate package for SNAC if the main package can do the trick? It is all about size and redistribution. In the above screen if you select&amp;#160; Show Additional Information you can se the sizes of the packages:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_10.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_thumb_4.png" width="786" height="166" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;As you can see the main package is ~232Mb while the SNAC package is ~7Mb. So for customers who have downloaded the SNAC redistributable package from the &lt;a href="http://www.microsoft.com/downloads/details.aspx?familyid=B33D2C78-1059-4CE2-B80D-2343C099BCB4&amp;amp;displaylang=en"&gt;SQL Server 2008 Feature Pack&lt;/a&gt;, having a separate SNAC package for a cumulative update is critical. Any time you see a separate package in the Cumulative update list, it is primarily because a particular software component was updated that could be installed outside the normal SQL Server installation, such as a feature pack component.&lt;/p&gt;  &lt;p&gt;Just so I can show the complete evidence here, let’s look at the SNAC files in each of these packages (read &lt;a href="http://thebackroomtech.com/2007/08/23/howto-extract-files-from-a-msi-file-using-the-windows-command-line/"&gt;this post&lt;/a&gt; to find out more about how to use msiexec to extract files from an msi package).&lt;/p&gt;  &lt;p&gt;If you extract the sqlncli.msi package (the SNAC package), you will find several files (mostly because we include the SDK lib files) but the one to drill in on is the sqlncli10.dll file. Here is my directory listing in Powershell for my extracted file:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_19.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_thumb_3.png" width="892" height="364" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;Now if I extract the main package files. (since this is an .EXE file you will need to use a tool like winzip to extract all the files from the .EXE) I will get the same file. When you do this extraction, the sqlncli.msi file will be in the path &amp;lt;platform&amp;gt;/setup/&amp;lt;platform&amp;gt; such as x64/setup/x64:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_21.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ShouldIhaveaSNACwithmycumulativeupdate_A7C0/image_thumb_6.png" width="895" height="393" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;This second set of files comes from the main CU package. You can see the sqlncli10.dll is the exact same date/time, file length, and version.&lt;/p&gt;  &lt;p&gt;Here are some other important points regarding SNAC and SQL Server 2008 Cumulative Updates:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;If you go look at Cumulative Update 1 and 2 for SQL Server 2008 SP1, you will notice there is no separate SNAC package. This is because no changes to SNAC were made for CU1 and CU2. Since there were no changes, there is no separate package and the main package doesn’t contain any updates to SNAC &lt;/li&gt;    &lt;li&gt;The first change to SNAC made after SQL Server 2008 SP1 was in Cumulative Update 3.&amp;#160; So a SNAC package was included and updates in the main package exist. &lt;/li&gt;    &lt;li&gt;This means from this point forward any cumulative update package for SQL Server 2008 SP1 will include a separate SNAC package and an update in the main package with an updated version even if no changes were made to SNAC. This is in line with how we do cumulative updates. This is why Cumulative Update 4 and 5&amp;#160; for SQL Server 2008 SP1 included a SNAC package and updates to SNAC in the main package (including a version that lines up with the engine for that &lt;/li&gt;    &lt;li&gt;Cumulative Updates for SQL Server 2008 RTM behave the same as SQL Server 2008 SP1. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;What about these other packages in SQL Server 2008 Cumulative Updates?. These are packages that are separable from the main CU package because they apply to different components related to SQL Server but installed through some other means such as a feature pack. As with SNAC, they only show up when an actual change is made. At that point, they will show up for each cumulative update package going forward for that service pack:&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;SQL_Server_2008_SP1_Cumulative_Update_NN_RSSharepoint&lt;/strong&gt; – These are updates that are specific to the SQL Server 2008 &lt;a href="http://www.microsoft.com/downloads/details.aspx?familyid=200FD7B5-DB7C-4B8C-A7DC-5EFEE6E19005&amp;amp;displaylang=en"&gt;Reporting Services Sharepoint Add-in&lt;/a&gt; that installs with Sharepoint Services. This package also exists for RTM CUs.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;SQL_Server_2008_SP1_Cumulative_Update_NN_RRB2ClickOn&lt;/strong&gt; – These are updates to the &lt;a href="http://blogs.msdn.com/sqlrsteamblog/archive/2009/04/17/some-help-with-report-builder-2-0-clickonce.aspx"&gt;Report Builder 2.0 ClickOnce&lt;/a&gt; package.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;What about SQL Server 2005?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;SQL Server 2005 is very similar to SQL Server 2008 in that a separate package is provided as an option when changes are made to that component. &lt;strong&gt;But&lt;/strong&gt;, a major difference for SNAC is that the SNAC updates &lt;strong&gt;ARE NOT&lt;/strong&gt; included in the main package.&lt;/p&gt;  &lt;p&gt;So on a SQL Server if you need SNAC updated, you must apply both the main and SNAC packages. &lt;strong&gt;This is something customers using linked servers should be very aware of.&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Another difference is some other separate packages exist that are not in SQL Server 2008. Like SQL Server 2008, these exist to update components that can be installed outside of the normal SQL Server installation. They may not exist in all cumulative update packages because they will only appear when a change is made (or any CU afterwards):&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;SQL_Server_2005_SP3_Cumulative_Update_NN_SQLWriter&lt;/strong&gt; – Updates for the Microsoft SQL Server VSS Writer Service used for SQL Server VSS backups. This package also exists for SP2 CUs.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;SQL_Server_2005_SP3_Cumulative_Update_NN_RS_Sharepo – &lt;/strong&gt;Like 2008, this is an update for the SQL Server 2005 Reporting Services Sharepoint Add-in. This package also exists for SP2 CUs.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;SQL_Server_2005_SP3_Cumulative_Update_NN_XMO – &lt;/strong&gt;This is an update to the &lt;b&gt;Microsoft SQL Server 2005 Management Objects Collection&lt;/b&gt; as found in the &lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=50B97994-8453-4998-8226-FA42EC403D17&amp;amp;displaylang=en"&gt;SQL Server 2005 Feature Pack&lt;/a&gt;. This package also exists for SP2 CUs.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;So for SNAC, here is a quick summary:&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;If you have installed SNAC as a separate installation (say from the feature pack), then just apply the SNAC package. This applies to SQL Server 2005 or 2008 &lt;/li&gt;    &lt;li&gt;If you have installed SQL Server 2008 on a client or server and want to make sure SNAC is updated, just apply the main cumulative update package. Any SNAC updates are included. &lt;/li&gt;    &lt;li&gt;if you have installed SQL Server 2005 on a client or server and want to make sure SNAC is updated, you need to apply the SNAC package in addition to the main cumulative update package &lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;Bob Ward    &lt;br /&gt;Microsoft&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9912097" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Setup" scheme="http://blogs.msdn.com/psssql/archive/tags/Setup/default.aspx" /><category term="Release" scheme="http://blogs.msdn.com/psssql/archive/tags/Release/default.aspx" /><category term="Cumulative Update" scheme="http://blogs.msdn.com/psssql/archive/tags/Cumulative+Update/default.aspx" /></entry><entry><title>Reporting Services and the MS09-062 GDR (GDI+)</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/10/15/reporting-services-and-the-ms09-062-gdr-gdi.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/10/15/reporting-services-and-the-ms09-062-gdr-gdi.aspx</id><published>2009-10-15T01:00:31Z</published><updated>2009-10-15T01:00:31Z</updated><content type="html">&lt;p&gt;&lt;em&gt;Updated 10/29/09:&amp;#160; Added section describing SQL Engine only servers at the bottom.&lt;/em&gt;&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Brian Hartman did a great job outlining what the GDR is and why we had it.&amp;#160; You can read it &lt;a href="http://blogs.msdn.com/brianhartman/archive/2009/10/13/gdi-updated-again.aspx" target="_blank"&gt;here&lt;/a&gt;.&amp;#160; I’m not going to rehash that here.&amp;#160; What I wanted to do is outline some of the scenarios involving the GDR.&amp;#160; The main thing to be aware of is Windows 2000.&amp;#160; Read the section “The transition” in Brian’s blog.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Scenario 1:&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;In this scenario, we have a Windows 2000 Client using Reporting Manager to render the report.&amp;#160; The Report Server &lt;em&gt;does not&lt;/em&gt; have the GDR applied.&amp;#160; The Windows 2000 Client get an error when they try to print - “Unable to load client print control” – once the kill bit has been released.&amp;#160; Clients on WinXP/Win2k3 or later will still be able to print fine.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen1_1.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Scen1" border="0" alt="Scen1" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen1_thumb_1.png" width="365" height="213" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Scenario 2:&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;In this scenario, we have a Windows 2000 Client using Report Manager to render the report.&amp;#160; The Report Server &lt;em&gt;does&lt;/em&gt; have the GDR applied.&amp;#160; In this case, everyone can print. &lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen2_1.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Scen2" border="0" alt="Scen2" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen2_thumb_1.png" width="365" height="213" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Scenario 3:&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;In this scenario, the RS Server is patched, but we have introduced another layer.&amp;#160; This layer would either be the Report Viewer Control (Win/Web Control) or hitting a report through SharePoint Integration.&amp;#160; In both cases, there is a manual update you need to perform to apply the GDR for either the SharePoint box, or the application using the Report Viewer Control.&amp;#160; In this case, they have not been updated yet, but the RS Server has been updated.&amp;#160; When the Win2K clients go to print, they will receive “Unable to load client print control”.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen3.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Scen3" border="0" alt="Scen3" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen3_thumb.png" width="508" height="216" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Scenario 4:&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;This scenario is the same as before, except we have updated the RVC and the SharePoint Add-in on the SharePoint Web Front End.&amp;#160; Any client should be able to print.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen4_1.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Scen4" border="0" alt="Scen4" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesandtheMS09062GDRGDI_11958/Scen4_thumb_1.png" width="515" height="210" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;How do I know if the GDR is applied?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;The build number is the best way to tell if the GDR is applied. These build numbers include this GDR.&amp;#160; The KB Articles associated with the releases includes the files that get updated.&lt;/p&gt;  &lt;table border="1" cellspacing="0" cellpadding="2" width="598"&gt;&lt;tbody&gt;     &lt;tr&gt;       &lt;td valign="top" width="283"&gt;&lt;strong&gt;Release&lt;/strong&gt;&lt;/td&gt;        &lt;td valign="top" width="313"&gt;&lt;strong&gt;Build number&lt;/strong&gt;&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="283"&gt;RS 2000 Service Pack 2&lt;/td&gt;        &lt;td valign="top" width="313"&gt;8.00.1067&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="283"&gt;RS 2005 Service Pack 2&lt;/td&gt;        &lt;td valign="top" width="313"&gt;9.00.3080&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="283"&gt;RS 2005 Service Pack 2 QFE (this will bring you up to Cumulative Update 15 as well)&lt;/td&gt;        &lt;td valign="top" width="313"&gt;9.00.3353&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="283"&gt;RS 2005 Service Pack 3&lt;/td&gt;        &lt;td valign="top" width="313"&gt;9.00.4053&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="283"&gt;RS 2005 Service Pack 3 QFE (This will bring you up to Cumulative Update 5)&lt;/td&gt;        &lt;td valign="top" width="313"&gt;9.00.4262&lt;/td&gt;     &lt;/tr&gt;   &lt;/tbody&gt;&lt;/table&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;What do you mean by QFE in the table above?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;By QFE, I mean that you are not running at base SP2 or SP3 for SQL 2005.&amp;#160; This means you have either applied a single hotfix, or have applied a Cumulative Update.&amp;#160; Because we are down that road, the GDR release is tied to whatever that last Cumulative Update was released which for SP2 was CU 15 and for SP3 was CU5.&lt;/p&gt;  &lt;p&gt;&lt;font color="#ff0000"&gt;Important Note:&lt;/font&gt; If you have more than Reporting Services on the server that you are applying the QFE version of the GDR to, it will also update any other services that you have on the box to that same build number (i.e. SQL Engine, Analysis Services, Integration Services, Tools, etc…).&amp;#160; SQL Native Client will not be updated.&lt;/p&gt;  &lt;p&gt;This could have some ramifications, both for RS as well as any other SQL Service you are running.&amp;#160; For example, if you have SQL Server 2005 SP2 CU7 with the following services installed (RS and Engine), once you apply the GDR you will then be upgraded to CU15 level of fixes.&amp;#160; Every fix between CU7 and CU15 will be applied to both RS and Engine.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Why am I having to install this for just the SQL Engine?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;We version bumped sqlservr.exe as part of the GDR.&amp;#160; No code change was actually made to the engine though.&amp;#160; As a result, if all you have is SQL Engine on your server, you will be flagged as needing this GDR if those conditions are met (based on your version as described above). As this GDR is specific to the RSClientPrint control and Reporting Services, your organization will have to determine if you want to apply it to your servers that only have SQL Engine and not Reporting Services.&amp;#160; Be aware about the Cumulative Update notes that were mentioned in the QFE topic above as that aspect will definitely affect the Engine based on the updates available in those cumulative fixes.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;font color="#808080"&gt;Adam W. Saxton | Microsoft SQL Server Escalation Services&lt;/font&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9907387" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="2005 SP2" scheme="http://blogs.msdn.com/psssql/archive/tags/2005+SP2/default.aspx" /><category term="SQL Server 2005 SP2" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2005+SP2/default.aspx" /><category term="Reporting Services" scheme="http://blogs.msdn.com/psssql/archive/tags/Reporting+Services/default.aspx" /><category term="SharePoint Integration" scheme="http://blogs.msdn.com/psssql/archive/tags/SharePoint+Integration/default.aspx" /><category term="Adam" scheme="http://blogs.msdn.com/psssql/archive/tags/Adam/default.aspx" /></entry><entry><title>Microsoft CSS is back at PASS again…</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/10/07/microsoft-css-is-back-at-pass-again.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/10/07/microsoft-css-is-back-at-pass-again.aspx</id><published>2009-10-07T04:54:32Z</published><updated>2009-10-07T04:54:32Z</updated><content type="html">&lt;p&gt;In little under a month (November 3-6), the &lt;a href="http://summit2009.sqlpass.org/"&gt;US PASS 2009 Summit&lt;/a&gt; is being held in Seattle, Washington at the downtown Seattle Convention Center. The Microsoft CSS team has been speaking and working at PASS since 2003 and this year we are back again. i thought I would share with you our involvement at this year’s conference as you may be thinking about whether you should attend or if attending what presentations and activities you should go to:&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;font size="4"&gt;Pre-Conference Seminar&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;This year we only have 1 pre-conference seminar (PASS this year is doing post-conference seminars but we are not participating in that). Adam Saxton, an escalation engineer in Texas, specializes in Reporting Services. Whenever I have any questions or issue on SSRS, I turn to Adam.&lt;/p&gt;  &lt;p&gt;So he will be presenting a day long seminar called &lt;strong&gt;&lt;a href="http://summit2009.sqlpass.org/Agenda/PrePostConferenceSessions/TacklingTopReportingServicesIssues.aspx"&gt;Tackling Top Reporting Services Issues&lt;/a&gt;. &lt;/strong&gt;Adam in this session will explain, review, and demonstrate what he does for a living everyday. That is solve problems customers have with Reporting Services. This includes but not limited to:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;How to look at server logs, configuration settings, and troubleshooting rendering issues &lt;/li&gt;    &lt;li&gt;Report Design issues such as pagination &lt;/li&gt;    &lt;li&gt;Issues with integration with Sharepoint &lt;/li&gt;    &lt;li&gt;Kerberos security issues &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;If I know Adam, there will be plenty of demonstrations to show during the day. If you work with Reporting Services and want to avoid problems, know how to handle certain situations, or plan better for deployment, you won’t want to miss this session&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;font size="4"&gt;Main Conference Talks&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;We have four main conference talks this year by CSS engineers. I’ve listed these in chronological order by date. Please note that in past conferences I’ve seen the agenda times and rooms change at the last minute, but this information is “as is” according to the &lt;a href="http://summit2009.sqlpass.org/LinkClick.aspx?fileticket=HiHpCCqTjbY%3d&amp;amp;tabid=68"&gt;posted schedule&lt;/a&gt; on the PASS website.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;(DBA-500-SC) &lt;a href="http://summit2009.sqlpass.org/Agenda/ProgramSessions/InsideSQLServerWaitTypes.aspx"&gt;Inside SQL Server Wait Types&lt;/a&gt;&lt;/strong&gt; – Bob Ward&lt;/p&gt;  &lt;p&gt;Tues 11/3 10:15 – 11:45am&amp;#160;&amp;#160; Room 3AB&lt;/p&gt;  &lt;p&gt;This is a “500” level talk which means it can be very deep and internal focused.&amp;#160; However, if you have sees “wait types” show up in DMVs like sys.dm_exec_requests and wonder what some of these mean you should attend this talk. For example, I’ll be covering wait types you can generally ignore and new wait types for SQL Server 2008 called “pre-emptive” wait types. I’ll also talk about a plan for us to document all of the wait types (at least the ones that you as customers need documentation on). In this session, I’m not going to spend much time on some of the very common “waits” you encounter every day such as locks, page latches (although I will talk about non-BUF latches), and network I/O. I’ll be going into the more obscure or advanced wait types, but also talk about things like the history behind wait types and the underlying algorithm for how they work. Plenty of demos in this talk including DMVs and Extended Events. Unlike my talk&amp;#160; last year on memory, I’m not sure this year’s talk will be as some said a 600 level talk, but I have no doubt the Windows Debugger will pop-up somewhere in the discussion&amp;lt;g&amp;gt;&lt;/p&gt;  &lt;p&gt;A very good complimentary session to attend is Andrew Kelly’s &lt;strong&gt;&lt;a href="http://summit2009.sqlpass.org/Agenda/SpotlightSessions/CapturingandAnalyzingFileWaitStats.aspx"&gt;Capturing and Analyzing File &amp;amp; Wait Stats.&lt;/a&gt;&lt;/strong&gt; This is where you will find a discussion on the common wait types. Andrew’s talk is scheduled right now for Thursday, 11/5 at 10:45am in Room 3AB&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;(DBA-X69-C) &lt;a href="http://summit2009.sqlpass.org/Agenda/ProgramSessions/ImplementingandSupportingSQL2008FailoverClus.aspx"&gt;Implementing and Supporting SQL 2008 Failover Clustering&lt;/a&gt;&lt;/strong&gt; - Shon Hauck&lt;/p&gt;  &lt;p&gt;Tues 11/3 1:30-2:45pm&amp;#160;&amp;#160; Room 4C1-2 &lt;/p&gt;  &lt;p&gt;Shon is the “goto” guy in SQL CSS for clustering and an escalation engineer based out of Charlotte, North Carolina. Before he joined our team he supported Windows clustering so he has knowledge of internals of both Windows and SQL Server clustering. Shon spent a great deal of time during the CTP launches of SQL Server 2008 giving the product team feedback on SQL Server 2008 clustering so he knows the “gotchas” before and after you deploy. If you have to support SQL Server 2008 in a clustered environment, this is a talk you need to attend. Shon always covers things in his talks that are hard to find in any online resource so I think you will come away with information you can use immediately when it comes to SQL failover clustering.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;(BIA-X45-C) &lt;a href="http://summit2009.sqlpass.org/Agenda/ProgramSessions/TopcustomersupportissuesinAnalysisServices2.aspx"&gt;Top customer support issues in Analysis Services&lt;/a&gt;&lt;/strong&gt; – John Sirmon&lt;/p&gt;  &lt;p&gt;Wed 11/4 1:30-2:45pm&amp;#160; Room 2AB &lt;/p&gt;  &lt;p&gt;Three or four years ago, all you would have seen from CSS at PASS are talks related to the SQL Sever engine. John’s talk shows how far we have come. John is an escalation engineer in our Charlotte office and brings a unique skill set that involves both Analysis Serves and Reporting Services. The full title of his talk is &lt;strong&gt;Top customer support issues in Analysis Services 2005/2008 and how to resolve them.&lt;/strong&gt; This is the type of information that CSS uniquely brings to the table at PASS. We can present to you what other customers are having problems with our software and give you solutions in the form of a talk. So John here will cover things like MDX Query Performance problems, how to handle some of the more innocuous errors like “the operation has been cancelled”, and a discussion of common design mistakes that can affect performance. Whether you manage an SSAS deployment or design SSAS objects and applications there are plenty of good tips here to make your deployment and operations of SSAS more efficient.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;(AD-X43-C) &lt;a href="http://summit2009.sqlpass.org/Agenda/ProgramSessions/TroubleshootingapplicationsaccessingSQLServer.aspx"&gt;Troubleshooting applications accessing SQL Server&lt;/a&gt;&lt;/strong&gt; - Abirami Iyer and Lakshmi Jonnakuti&lt;/p&gt;  &lt;p&gt;Thurs 11/5 1:00-2:15pm&amp;#160;&amp;#160; Room 613-614&lt;/p&gt;  &lt;p&gt;Many people don’t know but our CSS team helps developers of data “based” applications as well as the normal “server” products. So if you develop database applications you will want to attend this session. DBAs can benefit from this session as well as Abi and Lakshmi will cover connectivity and authentication issues for applications accessing SQL Server. You will definitely want to see them demonstrate some of the tools they use everyday including BID Tracing, Network Monitor (netmon), SQL Profiler, and the Windows Debugger. Abi and Lakshmi are both in our escalation services team based near Seattle in our Sammamish office. Their focus is on Developer technologies which we often call internally “WebData”. So they both know our developer data access technologies and help developers all of the time. But they both know how our providers interact with SQL Server so this is a great talk to see the “end to end” story when it comes to client/server SQL Server issues.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;font size="4"&gt;The SQL Server Clinic&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Last year we changed the brand name of the traditional SQL Server Service Center to the SQL Server First Aid Station. We focused our efforts on simply answering your questions about SQL Server technologies. This year we are going to change the brand name again and for a good reason. The past few years, we have found that we are sometimes pointing folks who have more “design” or “advisory” questions to the SQLCAT team. And the SQLCAT team found they were telling people with traditional “problems” to see CSS in the First Aid Station. So…. this year we will be in the same room together for something called the &lt;a href="http://summit2009.sqlpass.org/Agenda/MicrosoftatSummit.aspx#SQL_Server_First_Aid_Clinic"&gt;SQL Server Clinic&lt;/a&gt;.&amp;#160; And we also have moved the room to a more central location, Room 611 which is right in the “middle” of the hallways leading to the ballrooms on the 6th floor. I’ve been told our room will be larger than last year as well.&lt;/p&gt;  &lt;p&gt;Our CSS staff will include our speakers from the conference as well other engineers from our Sammamish office rotating in each day. This is really a unique opportunity to interact with our CSS and SQLCAT teams like no other opportunity I’ve ever seen. We cannot guarantee this is like “getting a free case” from CSS, but we definitely can point you in the right direction. I think many of our engineers also like meeting our customers face to face given we spend most of our time interacting with them over the phone or email. The questions we get in the clinic range from “how does this work” to “I have a crash can you look at it?”. In some situations in the past, I have been able to use my laptop or the customer’s and demonstrate to them how to solve a particular problem on the spot or by the end of the conference. They don’t all work out that way but I would say just about everyone that comes to us a with a question or problems leaves with more than when they walked in the door.&lt;/p&gt;  &lt;p&gt;The clinic will be open Tuesday through Thursday of the conference. We are still finalizing the hours but generally you should be able to talk to someone from a few minutes after the keynotes each day (we want to see them too&amp;lt;g&amp;gt;) until around 5 or 6pm.&lt;/p&gt;  &lt;p&gt;&amp;#160; &lt;/p&gt;  &lt;p&gt;Counting both US and Europe PASS conferences, this will be my 10th PASS Summit to speak and represent Microsoft. It is definitely something I look forward to every year. I would like to hear directly from many of you reading this that will be in attendance.. So please look me up after my talk, in the hallways, at lunch, at one of the evening events, or in the SQL Server Clinic. I’m open to striking up a conversation on anything related to SQL Server. Of course, sports is a big passion for me as well so if you want to also chat about your favorite sports team, it is always a great way to start a conversation with me. See you at PASS in November!&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Bob Ward    &lt;br /&gt;Microsoft&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9904072" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="PASS 2009" scheme="http://blogs.msdn.com/psssql/archive/tags/PASS+2009/default.aspx" /></entry><entry><title>Reporting Services:  What’s my version?</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/09/30/reporting-services-what-s-my-version.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/09/30/reporting-services-what-s-my-version.aspx</id><published>2009-09-30T02:57:15Z</published><updated>2009-09-30T02:57:15Z</updated><content type="html">&lt;p&gt;I was working on a case where I needed to try something on different Cumulative Updates (CU) to see what the result was in each.&amp;#160; Let me outline the version numbers for the Service Pack 1 release we have to date.&lt;/p&gt;  &lt;table border="1" cellspacing="0" cellpadding="2" width="400"&gt;&lt;tbody&gt;     &lt;tr&gt;       &lt;td valign="top" width="200"&gt;&lt;strong&gt;Release&lt;/strong&gt;&lt;/td&gt;        &lt;td valign="top" width="200"&gt;&lt;strong&gt;Version Number&lt;/strong&gt;&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="200"&gt;SQL 2008 RTM&lt;/td&gt;        &lt;td valign="top" width="200"&gt;10.00.1600&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="200"&gt;SQL 2008 SP1&lt;/td&gt;        &lt;td valign="top" width="200"&gt;10.00.2531&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="200"&gt;&lt;a href="http://support.microsoft.com/default.aspx?scid=kb;EN-US;969099" target="_blank"&gt;SP1 Cumulative Update 1&lt;/a&gt;&lt;/td&gt;        &lt;td valign="top" width="200"&gt;10.00.2710&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="200"&gt;&lt;a href="http://support.microsoft.com/default.aspx?scid=kb;EN-US;970315" target="_blank"&gt;SP1 Cumulative Update 2&lt;/a&gt;&lt;/td&gt;        &lt;td valign="top" width="200"&gt;10.00.2714&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="200"&gt;&lt;a href="http://support.microsoft.com/default.aspx?scid=kb;EN-US;971491" target="_blank"&gt;SP1 Cumulative Update 3&lt;/a&gt;&lt;/td&gt;        &lt;td valign="top" width="200"&gt;10.00.2723&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td valign="top" width="200"&gt;&lt;a href="http://support.microsoft.com/default.aspx?scid=kb;EN-US;973602" target="_blank"&gt;SP1 Cumulative Update 4&lt;/a&gt;&lt;/td&gt;        &lt;td valign="top" width="200"&gt;10.00.2734&lt;/td&gt;     &lt;/tr&gt;   &lt;/tbody&gt;&lt;/table&gt;  &lt;p&gt;After I had installed both CU1 and CU2, I noticed the following when I browsed to http://&amp;lt;server&amp;gt;/ReportServer.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/rsserver.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="rsserver" border="0" alt="rsserver" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/rsserver_thumb.png" width="368" height="277" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;When I looked at the RS Server Log, I found the following:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/rslog.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="rslog" border="0" alt="rslog" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/rslog_thumb.png" width="728" height="105" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;This made me think that the CU did not apply.&amp;#160; However, when connecting to my SQL Engine on the same box via Management Studio, I see the following&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/ssms.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="ssms" border="0" alt="ssms" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/ssms_thumb.png" width="218" height="244" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;This is the CU2 version.&amp;#160; The CU did apply.&amp;#160; So, why is the ReportServer page and the Log file indicating the SP1 base build number of 2531?&amp;#160; It is currently picking up the version number from ReportingServicesService.exe.&amp;#160; In the case of CU1 and CU2, the actual ReportingServicesService.exe file was not updated.&amp;#160; Only associated files were updated as part of that patch.&amp;#160; However, for CU3 and CU4 the EXE was updated.&lt;/p&gt;  &lt;p&gt;You might be asking what the right approach is to determine your version of Reporting Services.&amp;#160; And, if you call Support, the one of the things we are going to want to know if what Version you currently have.&amp;#160; We typically look at the Report Server Page and the RS Logs to get that information.&amp;#160; The current exception to this would be if it shows the base SP1 version, in which case we will need to check some other files to validate that you are really on SP1 or on a CU.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/Files.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="Files" border="0" alt="Files" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/Files_thumb.png" width="642" height="426" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;This is not the most ideal situation, but that is what is needed currently if you are looking for your version number.&amp;#160; Also be aware that even though CU3 and CU4 display the correct version, that doesn’t mean that CU5 will have the EXE updated.&amp;#160; The CU Articles list the file changes for that given patch.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/kb.png"&gt;&lt;img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="kb" border="0" alt="kb" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/ReportingServicesWhatsmyversion_10A78/kb_thumb.png" width="496" height="209" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt; If you don’t see this listed in the CU KB Article, then that means it was not updated and your version display will not be accurate from the Report Server Page or the log file.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;NOTE: &lt;/strong&gt;Another caveat to this is Management Studio when connection to Reporting Services.&amp;#160; Currently it still displays the RTM version number (10.00.1600) and should NOT but used to determine the version of Reporting Services on your Server.&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;font color="#808080"&gt;Adam W. Saxton | Microsoft SQL Server Escalation Services&lt;/font&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9901063" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="SQL Server 2008" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2008/default.aspx" /><category term="Reporting Services" scheme="http://blogs.msdn.com/psssql/archive/tags/Reporting+Services/default.aspx" /><category term="SQL Server 2008 SP1" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2008+SP1/default.aspx" /><category term="Adam" scheme="http://blogs.msdn.com/psssql/archive/tags/Adam/default.aspx" /><category term="SQL Server Management Studio" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+Management+Studio/default.aspx" /></entry><entry><title>Did your backup program/utility leave your SQL Server running in an squirrely scenario?</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/09/23/did-your-backup-program-utility-leave-your-sql-server-running-in-an-squirrely-scenario.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/09/23/did-your-backup-program-utility-leave-your-sql-server-running-in-an-squirrely-scenario.aspx</id><published>2009-09-23T23:58:30Z</published><updated>2009-09-23T23:58:30Z</updated><content type="html">&lt;p&gt;My colleges asked me if &lt;em&gt;'squirrely'&lt;/em&gt; is a technical term and for this post the answer is yes.&amp;#160; CSS is not going to deny support to customers but SQL Server was not tested in this scenario so you may have chased yourself up a tree, hence I use the term squirrely.&lt;/p&gt;  &lt;p&gt;SQL Server 2005 introduced snapshot databases and modified DBCC to create secondary snapshot streams for online DBCC operations.&amp;#160;&amp;#160; The online DBCC creates a secondary stream of the database files that is SPARSE.&amp;#160; CSS has found that if a 3rd party backups and utilities or NT Backup is used against the database files the SPARSE setting may get incorrectly, propagated to the parent stream.&amp;#160;&amp;#160; In the case of DBCC this is the original database files(s).&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;strong&gt;&lt;u&gt;Repro&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;    &lt;ul&gt;     &lt;li&gt;Create Database MyDB &lt;/li&gt;      &lt;li&gt;DBCC checkdb(MyDb)&amp;#160;&amp;#160; -- Completed without error &lt;/li&gt;      &lt;li&gt;Utility like NT Backup touches the database files&amp;#160; (&lt;font color="#ff0000"&gt;Incorrectly makes SPARSE sticky on on the main file stream&lt;/font&gt;) &lt;/li&gt;   &lt;/ul&gt; &lt;/blockquote&gt;  &lt;p&gt;The next time the database is opened (recovery, restart, etc…) the sparse attribute it detected by SQL Server and the status shown in sys.database_files is updated to indicate &lt;em&gt;is_sparse = TRUE&lt;/em&gt;.&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;&lt;/font&gt; &lt;/font&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;use MyDB&lt;/p&gt;    &lt;p&gt;select&lt;/p&gt; &lt;/blockquote&gt; &lt;font color="#000000" size="2"&gt;is_sparse&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;,&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;*&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;from&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;sys&lt;/font&gt;&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;.&lt;/font&gt;&lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;database_files&lt;/font&gt;&lt;/font&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;If the is_sparse is not equal to 0 it indicates that SQL Server is treating the file as a sparse file.&amp;#160; This causes alternate, inappropriate, code lines to be used in areas such as auto grow.&amp;#160; &lt;em&gt;Future releases of SQL Server may contain additional messages in the error log when this situation is encountered.&lt;/em&gt;&lt;/p&gt;  &lt;p&gt;The case I am working on today shows a primary database file (not a snapshot or secondary sparse stream) using the Windows API DeviceIoControl to zero the contents during an auto grow.&amp;#160;&amp;#160; This is not the normal code line as the DeviceIoControl to zero the contents is only used for sparse files.&amp;#160;&amp;#160; The MSDN documentation associated with this (&lt;a href="http://msdn.microsoft.com/en-us/library/aa364597(VS.85).aspx"&gt;http://msdn.microsoft.com/en-us/library/aa364597(VS.85).aspx&lt;/a&gt; - FSCTL_SET_ZERO_DATA) indicates that the processing may deallocate other locations in the file while handling the request.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&amp;quot;If the file is sparse or compressed, the NTFS file system may deallocate disk space in the file. This sets the range of bytes to zeroes (0) without extending the file size.&amp;quot;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;SQL Server does not support backup and restore of snapshot/sparse files so when the primary database is treated as sparse the SQL Server is running in untested situations and the support boundaries blur.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;What Should I Do?&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Run a query against each of your databases and look for the is_sparse &amp;lt;&amp;gt; 0.&amp;#160; For any files that are not snapshot databases you need to copy the data out of the file, drop the file, create a new file and load the data.&amp;#160; I.E.: Transfer your data to a new file.&lt;/p&gt;  &lt;p&gt;Then determine what utility is touching the file and propagating the sparse attribute and configure it to avoid the SQL Server files.&lt;/p&gt;  &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;span style="font-family: &amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;; color: #a6a6a6; font-size: 8pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi; mso-ansi-language: en-us; mso-fareast-font-family: &amp;#39;Times New Roman&amp;#39;; mso-fareast-theme-font: minor-fareast; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-fareast-language: en-us; mso-bidi-language: ar-sa; mso-no-proof: yes"&gt;Bob Dorr - Principal SQL Server Escalation Engineer&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;[Sep 27 Update]&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;One of the things I love about the blog interactions.&amp;#160; I have had a great list of questions related to this blog already so I would like to add a Q/A section.&lt;/p&gt;  &lt;p&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 11pt"&gt;Are you saying that if any Snapshots exist when using these third party tools that it could cause the is_sparse flag to be turned on?&lt;/span&gt;&lt;span style="color: black"&gt; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #993366; font-size: 10pt"&gt;[[rdorr]] No it is a Windows based issue.&amp;#160; When DBCC runs it creates a sparse stream.&amp;#160;&amp;#160; SQL destroys the stream at the end of DBCC but the sparse bit becomes ‘sticky’ and will get upgraded to the primary stream.&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;span style="color: black"&gt; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: black"&gt;&lt;font size="3"&gt;&lt;font face="Times New Roman"&gt;&amp;#160; &lt;/font&gt;        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 11pt"&gt;Is the problem because the snapshots exist _&lt;i&gt;while&lt;/i&gt;_ those backups are taking place?&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 11pt"&gt;&lt;/span&gt;&lt;span style="color: black"&gt;&lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #993366; font-size: 10pt"&gt;[[rdorr]] No, the DBCC just needs to be executed so at some time the secondary steam existed.&amp;#160;&amp;#160; It does not apply to snapshot databases (Create database for snapshot)&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;span style="color: black"&gt; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: black"&gt;&lt;font size="3"&gt;&lt;font face="Times New Roman"&gt;&amp;#160; &lt;/font&gt;        &lt;p&gt;&lt;/p&gt;     &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 11pt"&gt;In the case of the DBCC activity – is the problem only going to happen if the DBCC is taking place while the third party utility kicks in?&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 11pt"&gt;&lt;/span&gt;&lt;span style="color: black"&gt;&lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 12pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #993366; font-size: 10pt"&gt;[[rdorr]] No it can occur after DBCC has completed successfully.&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;span style="color: black"&gt; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;You talk about copying the contents out of one file and putting them into another file -- i'm assuming you are meaning a new FileGroup and moving the objects into a new filegroup to transfer all the data to the new filegroup. &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;&amp;#160; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;[[rdorr]] Yes a new file in the same file group or a new file group. &lt;/span&gt;        &lt;p&gt;&lt;/p&gt;     &lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;&lt;/span&gt;    &lt;p&gt;&amp;#160;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;The question I have there is that if it is the filegroup that contains the system objects for the database, how do we get that information over into the new file? &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;&lt;/span&gt;    &lt;p&gt;&amp;#160;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;[[rdorr]] New database you can't move system objects.&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt; &lt;/span&gt;        &lt;p&gt;&amp;#160;&lt;/p&gt;     &lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;&amp;#160; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;Is it not possible to change the SPARSE attribute on the file system back so that SQL treats the file correctly? &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;&amp;#160; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;[[rdorr]] Not cleanly.&amp;#160; If you have such a situation the file system is tracking it as a sparse file and we have all kinds of unknowns. &lt;/span&gt;        &lt;p&gt;&lt;/p&gt;     &lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;&lt;/span&gt;    &lt;p&gt;&amp;#160;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;This sounds to me like a very dangerous situation that could easily result in dataloss. &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;&amp;#160; &lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;[[rdorr]] Should not result in data loss.&amp;#160; NTFS tracks the correct allocations.&amp;#160; The problem is that sparse files are limited in size so you are running along and you can’t grow anymore or a backup may not restore.&amp;#160; This is where you get into possible data loss.&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;!!! NOTE !!! This brings up a good point.&amp;#160; After the problem is corrected you should take a full backup. &lt;/span&gt;        &lt;p&gt;&lt;/p&gt;     &lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;&lt;/span&gt;    &lt;p&gt;&amp;#160;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;Is the problem only encountered during growths?&amp;#160;&amp;#160; if so, should we disable growth until we can reset the file attribute or move the contents somehow to another file(group)?&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Tahoma&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: black; font-size: 10pt"&gt;&lt;/span&gt;    &lt;p&gt;&lt;/p&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;[[rdorr]] Grow shows the behavior but the file is already getting tracked as sparse.&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;b&gt;&lt;i&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #1f497d; font-size: 10pt"&gt;&amp;#160;&lt;/span&gt;&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;[Sep 29 Update] - HOW CAN I FIX THIS&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Continued work on this has revealed SQL 2005 and SQL 2008 differences.&amp;#160;&amp;#160;&amp;#160; Windows has published various KB articles on how to change a file at the NTFS level from sparse to non-sparse.&amp;#160;&amp;#160; The basics are a file copy.&amp;#160;&amp;#160; Copy expands the destination file (does not retain the sparse attribute).&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;font size="5"&gt;&lt;u&gt;FIX STEPS for SQL 2008&lt;/u&gt;&lt;/font&gt;&amp;#160;&amp;#160; &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;font color="#ff0000"&gt;!!! WARNING !!!&amp;#160; Take appropriate backups and precautions when attempting these corrections.&amp;#160; A failed step in this process could render the database unusable and you may lose data.&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;strong&gt;Close the database files&lt;/strong&gt;&lt;/li&gt; &lt;/ul&gt;  &lt;blockquote&gt;   &lt;p&gt;ALTER DATABASE MyDB OFFLINE&lt;/p&gt; &lt;/blockquote&gt;  &lt;ul&gt;   &lt;li&gt;&lt;strong&gt;Validate the sparse setting using an elevated admin cmd prompt&amp;#160; Examples shown below.&lt;/strong&gt;&lt;/li&gt; &lt;/ul&gt;  &lt;p style="margin: 3pt 3pt 0pt 33pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: olive; font-size: 10pt"&gt;C:\Program Files\Microsoft SQL Server\MSSQL10.SQL2008\MSSQL\DATA&amp;gt;fsutil sparse &lt;span style="background: yellow; mso-highlight: yellow"&gt;queryflag&lt;/span&gt; dbTest.mdf      &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 27pt" class="MsoNormal"&gt;&lt;b&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #92d050; font-size: 10pt"&gt;This file is NOT set as sparse       &lt;p&gt;&lt;/p&gt;     &lt;/span&gt;&lt;/b&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 27pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: olive; font-size: 10pt"&gt;     &lt;p&gt;&amp;#160;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 3pt 0pt 33pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: olive; font-size: 10pt"&gt;C:\Program Files\Microsoft SQL Server\MSSQL10.SQL2008\MSSQL\DATA&amp;gt;fsutil sparse &lt;span style="background: yellow; mso-highlight: yellow"&gt;queryflag&lt;/span&gt; dbTest.mdf      &lt;p&gt;&lt;/p&gt;   &lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 27pt" class="MsoNormal"&gt;&lt;b&gt;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: red; font-size: 10pt"&gt;This file is set as sparse       &lt;p&gt;&lt;/p&gt;     &lt;/span&gt;&lt;/b&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;font color="#004080"&gt;Note: File that are 'set as sparse' that are NOT databases created using 'CREATE DATABASE FOR SNAPSHOT' should be corrected.&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;ul&gt;   &lt;li&gt;&lt;strong&gt;Rename the database file&lt;/strong&gt;&lt;/li&gt; &lt;/ul&gt;  &lt;blockquote&gt;   &lt;p&gt;ren MyDB.mdf&amp;#160; MyDBSparse.mdf&lt;/p&gt; &lt;/blockquote&gt;  &lt;ul&gt;   &lt;li&gt;&lt;strong&gt;Copy the data into a new file.&amp;#160; (Note:&amp;#160; Do not copy with overwrite as copy will retain the sparse attribute)&lt;/strong&gt;&lt;/li&gt; &lt;/ul&gt;  &lt;blockquote&gt;   &lt;p&gt;copy MyDBSparse.mdf MyDb.mdf&lt;/p&gt; &lt;/blockquote&gt;  &lt;ul&gt;   &lt;li&gt;&lt;strong&gt;Use FSUtil to validate all files for the database are no longer sparse.&lt;/strong&gt;      &lt;br /&gt;&lt;/li&gt;    &lt;li&gt;Bring the database back online     &lt;br /&gt;      &lt;br /&gt;ALTER DATABASE MyDB ONLINE&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;VALIDATE&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Validate that is_sparse returns the expected outcome.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;use MyDB&lt;/p&gt;    &lt;p&gt;select &lt;font color="#000000" size="2"&gt;is_sparse&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;,&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;*&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;from&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;sys&lt;/font&gt;&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;.&lt;/font&gt;&lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;database_files&lt;/font&gt;&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;BACKUP&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Take a full SQL Server backup of the database and make sure other backups are no longer causing the issue to re-occur.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;u&gt;&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;&lt;u&gt;&lt;font size="5"&gt;FIX STEPS for SQL 2005&lt;/font&gt;&lt;/u&gt;&lt;/p&gt;  &lt;p&gt;Use the database copy wizard to copy the data into a new database or upgrade to SQL Server 2008 and use the steps outlined above.&amp;#160;&amp;#160; I tested the sp_detach_db on SQL 2005 with an sp_attach_db on SQL 2008 and the is_sparse status can be restored to the expected running state&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9898663" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Engine" scheme="http://blogs.msdn.com/psssql/archive/tags/Engine/default.aspx" /><category term="SQL Server 2008" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2008/default.aspx" /><category term="2008" scheme="http://blogs.msdn.com/psssql/archive/tags/2008/default.aspx" /><category term="2005" scheme="http://blogs.msdn.com/psssql/archive/tags/2005/default.aspx" /><category term="SQL 2005" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+2005/default.aspx" /></entry><entry><title>If you use linked server queries, you need to read this….</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/09/22/if-you-use-linked-server-queries-you-need-to-read-this.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/09/22/if-you-use-linked-server-queries-you-need-to-read-this.aspx</id><published>2009-09-22T22:49:54Z</published><updated>2009-09-22T22:49:54Z</updated><content type="html">&lt;p&gt;If you use the linked server feature with SQL Server 2005 and 2008, please read through this carefully. We have discovered several problems that can result in memory leak(s). The conditions are a bit complicated so let me try to describe the problems, how you could be affected, and what action(s) you can take.&lt;/p&gt;  &lt;p&gt;&lt;u&gt;&lt;strong&gt;SQL Server 2008&lt;/strong&gt;&lt;/u&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;ANY remote stored procedure execution will leak memory for each execution on the local server (the server where you initiated the remote procedure execution). The leak is not large for each execution (around 40 bytes) but over time this can add up. This specific problem involves the RETURN status of a stored procedure so there is no way to avoid it (even if you don’t use RETURN in your proc a return status is sent back to the client) if you execute remote stored procedures. &lt;/li&gt;    &lt;li&gt;If you use &lt;a href="http://msdn.microsoft.com/en-us/library/ms173829.aspx"&gt;sql_variant&lt;/a&gt; SQL Server data types you could also face a different memory leak (again on the local server only). These leaks can occur under the following conditions:&amp;#160; &lt;ul&gt;       &lt;li&gt;If you use a sql_variant type for an OUTPUT parameter of a remote stored procedure you will leak around 40 bytes just for using a sql_variant OUTPUT parameter (the leak is per parameter). If the &lt;strong&gt;value&lt;/strong&gt; of the parameter is of type char, varchar, nchar, nvarchar,binary, or varbinary, you will also leak the size of the value itself for each parameter. So a large character string over time could result in a considerable memory leak. &lt;/li&gt;     &lt;/ul&gt;      &lt;ul&gt;       &lt;li&gt;if you run a remote query that returns a result with a sql_variant column AND the value of the column is a char, varchar, nchar, nvarchar, binary, or varbinary value, you will leak the value of that variant for each row returned to the local server. This one has a potential to cause a fairly significant leak depending on how big the values are and how many rows are returned. &lt;/li&gt;     &lt;/ul&gt;   &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;u&gt;&lt;strong&gt;SQL Server 2005&lt;/strong&gt;&lt;/u&gt;&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;You are only affected by the sql_variant problems listed above. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;This problem occurs if the linked server query uses the the SQL Server Native Client (SNAC) provider (this will happen with both the SNAC9 and SNAC10 providers), or the Microsoft OLE-DB Provider for SQL Server. The problem is specific to how the SQL Server engine handles a &lt;a href="http://msdn.microsoft.com/en-us/library/cc879258.aspx"&gt;SSVARIANT&lt;/a&gt; structure so only applies to SQL Server providers. If you add a linked server query through Management Studio and pick “SQL Server” you are using the SQL Server Native Client so you would be subject to this problem.&lt;/p&gt;  &lt;p&gt;I’ve tried to plan head of time a FAQ on this topic to help fill in more details:&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;1) Are these memory leak problems fixed?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;The first problem is..…but not completely (yet). The first problem for a leak of return status values is fixed in &lt;a href="http://support.microsoft.com/kb/971491"&gt;SQL Server 2008 CU3 for SP1&lt;/a&gt; (See fix article &lt;a href="http://support.microsoft.com/kb/971622"&gt;http://support.microsoft.com/kb/971622&lt;/a&gt;). That problem doesn’t happen in SQL Server 2005 so no need for a fix with that version. We are also looking to create a fix for this in the next cumulative update for SQL Server 2008 RTM.&lt;/p&gt;  &lt;p&gt;For the sql_variant problem, we are also looking to create fixes for SQL Server 2005 CU6 for SP3 and for SQL Server 2008 RTM and SP1 in a future cumulative update.&lt;/p&gt;  &lt;p&gt;Please note that the fix for this problem is within the SQL Server Engine code, not in the SNAC code. Therefore, when you are applying a fix from the CU updates, you need to pick the complete update package. For SQL Server 2008 CU3 for SP1 this package is called SQL_Server_2008_SP1_Cumulative_Update_3. This package also includes any update to SNAC. The package called SQL_Server_2008_SP1_Cumulative_Update_3_SNAC just contains updates to the SNAC providers so don’t try to just pick this package to get a fix for this problem.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;2) What can I do to avoid the problem if a fix is not available yet?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Aside from not running remote procedures or using sql_variant columns, there is no way to avoid the problem. For 32bit customers, you may be able to mitigate VAS issues this problem causes by running all linked server queries out of process.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;3) What symptoms can I see due to this problem?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;It is possible you will never see a problem depending on which condition of the leak(s) you are hitting. For example, for the “return status” leak, the leak is only around 40 bytes for each procedure execution. You may run for weeks or even months without this causing a problem. For 32bit users, this may cause you problems quicker because of the limited amount of VAS space. Running the linked server out of process can definitely help your situation for 32bit. Note the memory that is leaked here is in the default Windows heap for the SQLSERVR.EXE process, not in the Buffer Pool. This is why for a 32bit SQL Server installation the problem might result in memory errors because the VAS is limited (e.g.MemToLeave)&lt;/p&gt;  &lt;p&gt;The problem was first reported to us because of a 32bit system that saw errors in the ERRORLOG like:&lt;/p&gt;  &lt;p&gt;&lt;var&gt;Date &lt;/var&gt;&lt;var&gt;Time &lt;/var&gt;&lt;var&gt;SPID &lt;/var&gt;AppDomain 1411 (mch.dbo[runtime].1516) is marked for unload due to memory pressure.     &lt;br /&gt;&lt;var&gt;Date &lt;/var&gt;&lt;var&gt;Time &lt;/var&gt;&lt;var&gt;SPID &lt;/var&gt;AppDomain 1411 (mch.dbo[runtime].1516) unloaded.&lt;/p&gt;  &lt;p&gt;These messages can occur due to memory pressure (typically VAS pressure for 32bit and physical memory pressure for 64bit). But there are other types of memory related errors that might occur due to a leak of heap memory.&lt;/p&gt;  &lt;p&gt;As future fixes for this problem are released, I’ll update this blog post&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Bob Ward    &lt;br /&gt;Microsoft&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9898160" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Engine" scheme="http://blogs.msdn.com/psssql/archive/tags/Engine/default.aspx" /><category term="&quot;Be Aware&quot; Problems" scheme="http://blogs.msdn.com/psssql/archive/tags/_2200_Be+Aware_2200_+Problems/default.aspx" /></entry><entry><title>You may not see the data you expect in Extended Event Ring Buffer Targets….</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/09/17/you-may-not-see-the-data-you-expect-in-extended-event-ring-buffer-targets.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/09/17/you-may-not-see-the-data-you-expect-in-extended-event-ring-buffer-targets.aspx</id><published>2009-09-17T18:16:12Z</published><updated>2009-09-17T18:16:12Z</updated><content type="html">&lt;p&gt;Not sure how many of you have started using the new Extended Events feature of SQL Server 2008. For those who have not, there are several good resources out there already for you mostly done by the community:&lt;/p&gt;  &lt;p&gt;&lt;a title="http://sqlblog.com/blogs/jonathan_kehayias/archive/2009/05/27/whitepaper-using-sql-server-2008-extended-events-published.aspx" href="http://sqlblog.com/blogs/jonathan_kehayias/archive/2009/05/27/whitepaper-using-sql-server-2008-extended-events-published.aspx"&gt;http://sqlblog.com/blogs/jonathan_kehayias/archive/2009/05/27/whitepaper-using-sql-server-2008-extended-events-published.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;&lt;a title="http://sqlblog.com/blogs/adam_machanic/archive/2009/04/22/teched-coming-up-recommend-background-for-my-extended-events-talk.aspx" href="http://sqlblog.com/blogs/adam_machanic/archive/2009/04/22/teched-coming-up-recommend-background-for-my-extended-events-talk.aspx"&gt;http://sqlblog.com/blogs/adam_machanic/archive/2009/04/22/teched-coming-up-recommend-background-for-my-extended-events-talk.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;&lt;a title="http://technet.microsoft.com/en-us/magazine/2009.01.sql2008.aspx" href="http://technet.microsoft.com/en-us/magazine/2009.01.sql2008.aspx"&gt;http://technet.microsoft.com/en-us/magazine/2009.01.sql2008.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;I also have a few blog posts on our CSS blog that may interest you as well:&lt;/p&gt;  &lt;p&gt;&lt;a title="http://blogs.msdn.com/psssql/archive/2008/07/15/supporting-sql-server-2008-the-system-health-session.aspx" href="http://blogs.msdn.com/psssql/archive/2008/07/15/supporting-sql-server-2008-the-system-health-session.aspx"&gt;http://blogs.msdn.com/psssql/archive/2008/07/15/supporting-sql-server-2008-the-system-health-session.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;&lt;a title="http://blogs.msdn.com/psssql/archive/2009/04/30/why-should-i-use-extended-events-in-sql-server-2008.aspx" href="http://blogs.msdn.com/psssql/archive/2009/04/30/why-should-i-use-extended-events-in-sql-server-2008.aspx"&gt;http://blogs.msdn.com/psssql/archive/2009/04/30/why-should-i-use-extended-events-in-sql-server-2008.aspx&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;So enough plugging, what about this problem I refer to in the title? As we in CSS have used in XEvent (can’t help myself this is what we call this feature internally) and seen feedback from others in the community (See Jonathan’s Connect post at &lt;a title="http://connect.microsoft.com/SQLServer/feedback/ViewFeedback.aspx?FeedbackID=432548" href="http://connect.microsoft.com/SQLServer/feedback/ViewFeedback.aspx?FeedbackID=432548"&gt;http://connect.microsoft.com/SQLServer/feedback/ViewFeedback.aspx?FeedbackID=432548&lt;/a&gt;), a limitation has been found with the “Ring Buffer” target.&lt;/p&gt;  &lt;p&gt;If you have an event session setup for a ring_buffer target and the data you feed the target exceeds 4Mb, you may not be able to retrieve all XML nodes from the target data. This behavior can look like “torn XML” where some of the pieces of a captured extended event cannot be seen.&lt;/p&gt;  &lt;p&gt;Let me be more specific about this problem and what I mean by the 4Mb limit. Data is retrieved for “in-memory” targets such as ring_buffer from querying the column target_data from sys.dm_xe_session_targets. An example query for the installed &lt;a href="http://blogs.msdn.com/psssql/archive/2008/07/15/supporting-sql-server-2008-the-system-health-session.aspx"&gt;system_health session&lt;/a&gt; looks like this:&lt;/p&gt;  &lt;p&gt;select s.name, CAST(t.target_data as xml)   &lt;br /&gt;from sys.dm_xe_session_targets t    &lt;br /&gt;join sys.dm_xe_sessions s    &lt;br /&gt;on t.event_session_address = s.address    &lt;br /&gt;and s.name = 'system_health'&lt;/p&gt;  &lt;p&gt;If you look at the definition of the sys.dm_xe_session_target DMV in our documentation, the target_data column is defined as nvarchar(max). But in reality this column this column is limited to 4Mb of formatted XML text.&lt;/p&gt;  &lt;p&gt;The data produced for an in-memory target is binary as it is produced and consumed within the engine. But when you query the DMV we format the internal data into XML. It is the formatted, expanded XML data that is limited to 4Mb.&amp;#160; Here is where it might be confusing. An XEvent target has a “max memory” for its buffering but that is for the binary version of the data. By default, this value is 4Mb, but you can change this when you create an event session. However, for “in-memory” targets you will never be able to see more than &lt;strong&gt;4Mb of formatted XML&lt;/strong&gt;. It is very possible for the binary data collected in an in-memory target to be less than 4MB but the formatted version of the XML exceeds 4Mb.&lt;/p&gt;  &lt;p&gt;You are more likely to see an issue like this when setting up an event session where a lot of text is formatted from the target (Some possible examples are events like xml_deadlock_report, sql_statement_starting,…) or if you use actions such as sql_text.&lt;/p&gt;  &lt;p&gt;There are a few solutions here should you encounter the problem.&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;Use a file target such as asynchronous_file_target or etw_classic_sync_target&lt;/li&gt;    &lt;li&gt;Set the MAX_MEMORY of your target for the event session lower than 4Mb. This second solution is not something that will guarantee you won’t hit the problem because it is impossible to determine what is the right size to avoid the 4Mb limit of the formatted XML You will need to experiment with whatever events and actions you are using for your session. When using this method (and even if you didn’t limit your memory), you can query the DMV and save off the results to a file periodically.&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;This problem can occur for any “in-memory” target including ring_buffer, synchronous_bucketizer, asynchronous_bucketizer, pair_matching, and synchronous_event_counter since all of these targets require you to query the sys.dm_xe_session_target DMV to retrieve your data. Note that the probabilities are higher for a ring_buffer target since this is just a “raw feed” of the event data while the others listed here are aggregations of events.&lt;/p&gt;  &lt;p&gt;Bob Ward   &lt;br /&gt;Microsoft&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9896381" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Extended Events" scheme="http://blogs.msdn.com/psssql/archive/tags/Extended+Events/default.aspx" /><category term="SQL Server 2008" scheme="http://blogs.msdn.com/psssql/archive/tags/SQL+Server+2008/default.aspx" /></entry><entry><title>How It Works: What are the RING_BUFFER_RESOURCE_MONITOR telling me?</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/09/17/how-it-works-what-are-the-ring-buffer-resource-monitor-telling-me.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/09/17/how-it-works-what-are-the-ring-buffer-resource-monitor-telling-me.aspx</id><published>2009-09-17T17:08:00Z</published><updated>2009-09-17T17:08:00Z</updated><content type="html">&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The ring buffer records (which can be sent to XEvent) for Resource Monitor and Memory Broker are the key aspects to understanding RM.&amp;#160; The record is produced when a change is detected in state monitored by RM.&amp;#160; &lt;/font&gt;&lt;/span&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: blue; font-size: 10pt"&gt;&amp;#160;&lt;/span&gt;&lt;/font&gt;&lt;/span&gt; &lt;/p&gt;  &lt;blockquote&gt;   &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: blue; font-size: 10pt"&gt;CREATE&lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;EVENT&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;SESSION&lt;/span&gt;&lt;font color="#000000"&gt; RingBufferInfo &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: blue; font-size: 10pt"&gt;ON&lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;SERVER &lt;/span&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;#160;&amp;#160;&amp;#160; &lt;/font&gt;&lt;span style="color: blue"&gt;ADD&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;EVENT&lt;/span&gt;&lt;font color="#000000"&gt; sqlos&lt;/font&gt;&lt;span style="color: gray"&gt;.&lt;/span&gt;&lt;font color="#000000"&gt;resource_monitor_ring_buffer_recorded&lt;/font&gt;&lt;span style="color: gray"&gt;, &lt;/span&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;#160;&amp;#160;&amp;#160; &lt;/font&gt;&lt;span style="color: blue"&gt;ADD&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;EVENT&lt;/span&gt;&lt;font color="#000000"&gt; sqlos&lt;/font&gt;&lt;span style="color: gray"&gt;.&lt;/span&gt;&lt;font color="#000000"&gt;memory_broker_ring_buffer_recorded &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;#160;&amp;#160;&amp;#160; &lt;/font&gt;&lt;span style="color: blue"&gt;ADD&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;TARGET&lt;/span&gt;&lt;font color="#000000"&gt; package0&lt;/font&gt;&lt;span style="color: gray"&gt;.&lt;/span&gt;&lt;font color="#000000"&gt;asynchronous_file_target &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: blue; font-size: 10pt"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: gray; font-size: 10pt"&gt;(&lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: blue; font-size: 10pt"&gt;SET&lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;filename&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: gray"&gt;=&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: red"&gt;N'E:\XEvent\RingBuffer.etx'&lt;/span&gt;&lt;span style="color: gray"&gt;,&lt;/span&gt;&lt;font color="#000000"&gt; metadatafile &lt;/font&gt;&lt;span style="color: gray"&gt;=&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: red"&gt;N'E:\XEvent\RingBuffer.mta'&lt;/span&gt;&lt;span style="color: gray"&gt;, &lt;/span&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; max_file_size &lt;/font&gt;&lt;span style="color: gray"&gt;=&lt;/span&gt;&lt;font color="#000000"&gt; 50&lt;/font&gt;&lt;span style="color: gray"&gt;,&lt;/span&gt;&lt;font color="#000000"&gt; max_rollover_files &lt;/font&gt;&lt;span style="color: gray"&gt;=&lt;/span&gt;&lt;font color="#000000"&gt; 10&lt;/font&gt;&lt;span style="color: gray"&gt;)&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p&gt;&lt;/p&gt;    &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;#160;&amp;#160;&amp;#160; &lt;/font&gt;&lt;span style="color: blue"&gt;WITH &lt;/span&gt;&lt;span style="color: gray"&gt;(&lt;/span&gt;&lt;font color="#000000"&gt;MAX_MEMORY&lt;/font&gt;&lt;span style="color: gray"&gt;=&lt;/span&gt;&lt;font color="#000000"&gt;4MB&lt;/font&gt;&lt;span style="color: gray"&gt;,&lt;/span&gt;&lt;font color="#000000"&gt; MAX_EVENT_SIZE&lt;/font&gt;&lt;span style="color: gray"&gt;=&lt;/span&gt;&lt;font color="#000000"&gt;4MB&lt;/font&gt;&lt;span style="color: gray"&gt;,&lt;/span&gt;&lt;font color="#000000"&gt;STARTUP_STATE &lt;/font&gt;&lt;span style="color: gray"&gt;=&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;ON&lt;/span&gt;&lt;span style="color: gray"&gt;);&lt;/span&gt;&lt;/span&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Allow me to breakdown the following record.&amp;#160;&amp;#160;&amp;#160; ( &lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;select&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;*&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;from&lt;/font&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;sys&lt;/font&gt;&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;.&lt;/font&gt;&lt;/font&gt;&lt;font color="#008000" size="2"&gt;&lt;font color="#008000" size="2"&gt;dm_os_ring_buffers &lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;where&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; ring_buffer_type &lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;=&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;&lt;font color="#ff0000" size="2"&gt;'RING_BUFFER_RESOURCE_MONITOR'&amp;#160; )&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;font face="Calibri"&gt;&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;ResourceMonitor&amp;gt; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;Notification&amp;gt;RESOURCE_MEMPHYSICAL_LOW&amp;lt;/Notification&amp;gt;&amp;#160; &lt;/font&gt;&lt;font color="#008080"&gt;&amp;lt;---------------- Current notification state being broadcast to clerks &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;IndicatorsProcess&amp;gt;2&amp;lt;/IndicatorsProcess&amp;gt;&amp;#160;&amp;#160; &lt;font color="#008080"&gt;&amp;lt;-----------------------&amp;#160;&amp;#160; Indicator applies to the process as low physical memory&lt;/font&gt; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;IndicatorsSystem&amp;gt;0&amp;lt;/IndicatorsSystem&amp;gt; &lt;/font&gt;&lt;font color="#008080"&gt;&amp;lt;-----------------------&amp;#160; 0 means it is NOT a system wide indicator situation &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;NodeId&amp;gt;0&amp;lt;/NodeId&amp;gt; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;Effect type=&amp;quot;APPLY_LOWPM&amp;quot; state=&amp;quot;EFFECT_OFF&amp;quot; reversed=&amp;quot;0&amp;quot;&amp;gt;0&amp;lt;/Effect&amp;gt; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;Effect type=&amp;quot;APPLY_HIGHPM&amp;quot; state=&amp;quot;EFFECT_IGNORE&amp;quot; reversed=&amp;quot;0&amp;quot;&amp;gt;128163281&amp;lt;/Effect&amp;gt; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt;&amp;lt;Effect type=&amp;quot;REVERT_HIGHPM&amp;quot; state=&amp;quot;EFFECT_OFF&amp;quot; reversed=&amp;quot;0&amp;quot;&amp;gt;0&amp;lt;/Effect&amp;gt; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;font color="#000000"&gt;&lt;span style="font-family: &amp;quot;Arial&amp;quot;,&amp;quot;sans-serif&amp;quot;; font-size: 10pt"&gt;&amp;lt;/ResourceMonitor&amp;gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&amp;#160;&lt;/span&gt;&lt;/font&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The RM record has 3 major components showing various memory details. &lt;/font&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; The &amp;lt;RESOURCEMONITOR&amp;gt; portion of the record is handled from the local resource monitor.&amp;#160;&amp;#160; You have a RM per scheduling node.&amp;#160; &lt;br /&gt;&lt;/font&gt;&lt;/span&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; The &amp;lt;MEMORYNODE&amp;gt; details are from the memory node association or the RM.&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; The &amp;lt;MEMORYRECORD&amp;gt; comes from global state information. &lt;/font&gt;&lt;/span&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The key for understanding why RM is running is in the ResourceMonitor section of the output.&amp;#160;&amp;#160; This can be broken down into the Notification, Indicators and Effects. &lt;/font&gt;&lt;/span&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;   &lt;table style="margin: auto auto auto 30.2pt; border-collapse: collapse; mso-yfti-tbllook: 1184; mso-padding-alt: 0in 0in 0in 0in" class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;       &lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes"&gt;         &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 125.6pt; padding-right: 5.4pt; border-top: black 1pt solid; border-right: black 1pt solid; padding-top: 0in" valign="top" width="167"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Notification &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;            &lt;p&gt;&lt;/p&gt;         &lt;/td&gt;          &lt;td style="border-bottom: black 1pt solid; padding-bottom: 0in; background-color: transparent; padding-left: 5.4pt; width: 353.2pt; padding-right: 5.4pt; border-left-color: #f0f0f0; border-top: black 1pt solid; border-right: black 1pt solid; padding-top: 0in" valign="top" width="471"&gt;           &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Considered the broadcasted notification state.&lt;/font&gt;&lt;/span&gt;&lt;font color="#000000" size="2"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; &lt;/font&gt;&lt;/p&gt;            &lt;pre&gt;&lt;font color="#000000" size="2"&gt;RESOURCE_MEMPHYSICAL_HIGH - SQL can grow memory usage&lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;RESOURCE_MEMPHYSICAL_LOW - System or internal physical memory - shrink&lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;RESOURCE_MEM_STEADY &lt;br /&gt;&lt;/font&gt;&lt;font size="2"&gt;&lt;font color="#000000"&gt;RESOURCE_MEMVIRTUAL_LOW&lt;/font&gt;&lt;/font&gt;&lt;span style="color: #003300; font-size: 10pt"&gt; &lt;font face="Calibri"&gt; –  Virtual address range for SQL Server process is becoming exhausted.   Commonly the largest free block is less than 4MB.&lt;/font&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/pre&gt;
        &lt;/td&gt;
      &lt;/tr&gt;

      &lt;tr style="mso-yfti-irow: 1"&gt;
        &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 125.6pt; padding-right: 5.4pt; border-right: black 1pt solid; padding-top: 0in" valign="top" width="167"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;IndicatorsProcess &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;
        &lt;/td&gt;

        &lt;td style="border-bottom: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 353.2pt; padding-right: 5.4pt; border-left-color: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="471"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Process wide indicator using an |= of the following values&lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;pre&gt;&lt;font color="#000000" size="2"&gt;IDX_MEMPHYSICAL_HIGH = 1&lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;IDX_MEMPHYSICAL_LOW = 2&lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;IDX_MEMVIRTUALL_LOW = 4&lt;/font&gt;&lt;span style="color: #003300; font-size: 10pt"&gt; &lt;/span&gt;&lt;/pre&gt;
        &lt;/td&gt;
      &lt;/tr&gt;

      &lt;tr style="mso-yfti-irow: 2"&gt;
        &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 125.6pt; padding-right: 5.4pt; border-right: black 1pt solid; padding-top: 0in" valign="top" width="167"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;IndicatorsSystem &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;
        &lt;/td&gt;

        &lt;td style="border-bottom: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 353.2pt; padding-right: 5.4pt; border-left-color: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="471"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;System wide indicator an |= of the following values&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;pre&gt;&lt;font color="#000000" size="2"&gt;IDX_MEMPHYSICAL_HIGH = 1&lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;IDX_MEMPHYSICAL_LOW = 2&lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;IDX_MEMVIRTUALL_LOW = 4&lt;/font&gt; &lt;/pre&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;It is considered a system indicator if the query routine returns TRUE.&amp;#160;&amp;#160; SQL Server listens to the Windows physical memory notifications so it can be signaled when physical memory becomes low or available. &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;
                  &lt;br /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;This state is often the windows memory notifications unless an override occurs because of &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font size="3"&gt;&lt;font color="#000000"&gt;&lt;font face="Calibri"&gt;the the EFFECT information.&lt;span style="color: #003300; font-size: 10pt"&gt; &lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;
        &lt;/td&gt;
      &lt;/tr&gt;

      &lt;tr style="mso-yfti-irow: 3"&gt;
        &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 125.6pt; padding-right: 5.4pt; border-right: black 1pt solid; padding-top: 0in" valign="top" width="167"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Effect &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;
        &lt;/td&gt;

        &lt;td style="border-bottom: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 353.2pt; padding-right: 5.4pt; border-left-color: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="471"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Currently 3 types of effects exist so a row for each is produced. &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Type = indicator type 
                &lt;br /&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;State = current effect state&amp;#160; (ON, OFF or IGNORE are valid states) 
                &lt;br /&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Reserved= this maps to an applied state that toggles from 0 or 1 based on if the effect has been applied.&amp;#160; Applied indicates that the memory state has broadcast and we have achieved somewhat of a steady state for this indicator. &lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Value = duration that the effect has been in the reported state. &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;
        &lt;/td&gt;
      &lt;/tr&gt;

      &lt;tr style="mso-yfti-irow: 4; mso-yfti-lastrow: yes"&gt;
        &lt;td style="border-bottom: black 1pt solid; border-left: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 125.6pt; padding-right: 5.4pt; border-right: black 1pt solid; padding-top: 0in" valign="top" width="167"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;NodeId &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;
        &lt;/td&gt;

        &lt;td style="border-bottom: black 1pt solid; padding-bottom: 0in; background-color: transparent; border-top-color: #f0f0f0; padding-left: 5.4pt; width: 353.2pt; padding-right: 5.4pt; border-left-color: #f0f0f0; border-right: black 1pt solid; padding-top: 0in" valign="top" width="471"&gt;
          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;Memory Node association of the RM.&lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p&gt;&lt;/p&gt;

          &lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;/p&gt;
        &lt;/td&gt;
      &lt;/tr&gt;
    &lt;/tbody&gt;&lt;/table&gt;
&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The notification is the current RM state.&amp;#160; For example, once RM detects LOW PM state it is going to execute and attempt to shrink caches and other memory users.&amp;#160;&amp;#160;&amp;#160; &lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The indicators tell you if this is an internal or external condition.&amp;#160;&amp;#160; System wide indicates the system had a hand in the indication and process means it was something internal that SQL Server detected. &lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;The Effects represent the state SQL thinks it is in by looking at the working set size and basic memory targets.&amp;#160;&amp;#160; The EFFECT logic is used during system level checks.&amp;#160;&amp;#160; For example the RM can look at the physical memory and it shows high but the effects indicate Windows paged SQL Server out so the high should be ignored so we don’t consume more memory and cause more paging.&amp;#160;&amp;#160;&amp;#160; The effects logic can be disabled using a startup trace flag –T8020 to avoid honoring the memory effects&lt;i&gt;.&amp;#160;&amp;#160; This might be an option on the servers to narrow down what can trigger RM to execute as long as the working sets of the SQL Server instances are running steady with the target memory but it should only be used for troubleshooting purposes. &lt;/i&gt;&lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;From the ring buffer example is stating that this is not a system wide issue but a process issue.&amp;#160;&amp;#160; The effects are off or ignore so it is not a working set type of issue so what turns this on to low physical?&amp;#160;&amp;#160; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;There are memory broker decisions that come into play at this time.&amp;#160;&amp;#160; What the information is is saying is that a cache or the cache’s predicted usage will exceed internal targets and we need to start doing cache cleanup.&amp;#160;&amp;#160;&amp;#160; &lt;/font&gt;&lt;/span&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;By looking at the memory broker, ring buffer entries, you can see the behavior that broker it asking of RM.&amp;#160;&amp;#160; Using the clock hands you can see the internal and external hand movement.&amp;#160;&amp;#160; This will help you determine which caches are involved.&amp;#160;&amp;#160;&amp;#160; The dbcc memorystatus() show good details and last notification states as well.&amp;#160;&amp;#160; &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;When the SHRINK appears this is when it could tell RM to help out and result in RM showing the ring buffer above of LOW PM. &lt;/font&gt;&lt;/span&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="text-indent: 0.5in; margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; color: blue; font-size: 10pt"&gt;select&lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt"&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: gray"&gt;*&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: blue"&gt;from&lt;/span&gt;&lt;font color="#000000"&gt; &lt;/font&gt;&lt;span style="color: green"&gt;sys&lt;/span&gt;&lt;span style="color: gray"&gt;.&lt;/span&gt;&lt;span style="color: green"&gt;dm_os_memory_cache_clock_hands&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #003300; font-size: 10pt"&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;&lt;font color="#000000"&gt;MEMORYBROKER_FOR_CACHE (default)&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; Pages &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;&lt;font color="#000000"&gt;---------------------------------------- ----------- &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;&lt;font color="#000000"&gt;Allocations&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 1778 &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;&lt;font color="#000000"&gt;Rate&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 0 &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;&lt;font color="#000000"&gt;Target Allocations&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 460798 &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;&lt;font color="#000000"&gt;Future Allocations&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 0 &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;&lt;font color="#000000"&gt;Overall&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 482733 &lt;/font&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt 0.5in" class="MsoNormal"&gt;&lt;font color="#000000"&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;Last Notification&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; 1&amp;#160; &lt;/span&gt;&lt;span style="font-family: wingdings; font-size: 8pt"&gt;ß&lt;/span&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt;---------------------------&lt;/span&gt;&lt;font size="3"&gt;&lt;font face="Calibri"&gt;&amp;#160; Memory Broker NOTIFICATION&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;span style="font-family: &amp;quot;Courier New&amp;quot;; font-size: 8pt"&gt; &lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;font color="#000000" size="2"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; ACTIONS (STABLE) = 0 
    &lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; ACTIONS (GROW) = 1 
    &lt;br /&gt;&lt;/font&gt;&lt;font color="#000000" size="2"&gt;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160;&amp;#160; ACTIONS (SHRINK) = 2&lt;/font&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;&lt;font face="Calibri"&gt;&amp;#160;&lt;span style="font-family: &amp;quot;Calibri&amp;quot;,&amp;quot;sans-serif&amp;quot;; color: #a6a6a6; font-size: 8pt; mso-bidi-font-family: &amp;#39;Times New Roman&amp;#39;; mso-bidi-theme-font: minor-bidi; mso-ansi-language: en-us; mso-fareast-font-family: &amp;#39;Times New Roman&amp;#39;; mso-fareast-theme-font: minor-fareast; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-fareast-language: en-us; mso-bidi-language: ar-sa; mso-no-proof: yes"&gt;Bob Dorr - Principal SQL Server Escalation Engineer&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;/p&gt;

&lt;p style="margin: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="color: #993366; font-size: 10pt"&gt;&lt;font face="Calibri"&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9896345" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Engine" scheme="http://blogs.msdn.com/psssql/archive/tags/Engine/default.aspx" /><category term="2005 SP2" scheme="http://blogs.msdn.com/psssql/archive/tags/2005+SP2/default.aspx" /><category term="Memory" scheme="http://blogs.msdn.com/psssql/archive/tags/Memory/default.aspx" /><category term="How It Works" scheme="http://blogs.msdn.com/psssql/archive/tags/How+It+Works/default.aspx" /><category term="2008" scheme="http://blogs.msdn.com/psssql/archive/tags/2008/default.aspx" /><category term="2005" scheme="http://blogs.msdn.com/psssql/archive/tags/2005/default.aspx" /></entry><entry><title>Fun with Locked Pages, AWE, Task Manager, and the Working Set…</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/psssql/archive/2009/09/11/fun-with-locked-pages-awe-task-manager-and-the-working-set.aspx" /><id>http://blogs.msdn.com/psssql/archive/2009/09/11/fun-with-locked-pages-awe-task-manager-and-the-working-set.aspx</id><published>2009-09-11T22:40:37Z</published><updated>2009-09-11T22:40:37Z</updated><content type="html">&lt;p&gt;I realize that the topic of “locked pages’ and AWE can be confusing. I don’t blame anyone for being confused on this. I also realize we have blogged and talked about this topic many times perhaps “beating it to death”. And I certainly know this is not really fun to anyone(but it made for a catchy title). But I still get questions both from customers and internally within Microsoft about these topics for both 32bit and 64bit SQL Server systems. So I thought a blog post that summarizes and clarifies a few points might be valuable. Maybe this will be the one resource that “turns on the light” for you. Many people respond well to a “FAQ” so I’ll create this topic in that format. I recommend you read through each FAQ one at time in order, because some of the answers need to be read first to understand the ones below it:&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;1. What is the difference between AWE on 32bit systems and “Locked Pages” on 64bit systems?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;I think it is all about using the right terms. SQL Server introduced a “feature” called AWE before we even shipped a 64bit version of SQL Server. The concept was to extend the ability of SQL Server to address more memory than the limits of the virtual address space (VAS) on 32bit systems (which is 2Gb-3Gb). But the SQL team couldn’t do this alone. So the Windows team built an API to support this capability called &lt;a href="http://msdn.microsoft.com/en-us/library/aa366527(VS.85).aspx"&gt;Address Windowing Extensions&lt;/a&gt;.(AWE) If you want to go a step further and find out what is the difference between Physical Address Extensions (PAE) and AWE, read this &lt;a href="http://msdn.microsoft.com/en-us/library/aa366796(VS.85).aspx"&gt;resource&lt;/a&gt;. &lt;/p&gt;  &lt;p&gt;One of the interesting effects for any application that uses the AWE API is that any memory allocated with these APIs is not part of the process working set. Therefore, Windows considered this memory as “locked” (i.e. cannot be paged to disk). Therefore, the user who launches an app that uses the AWE API must have the “Locked Pages in Memory” privilege (for example the service account for SQL Server) set.&lt;/p&gt;  &lt;p&gt;So now the SQL team introduces a x64 edition of SQL Server with SQL Server 2005. Because a process running on x64 doesn’t have the same VAS limits as 32bit (the numbers are crazy here. Theoretically, a 64bit process has a 16 Exabyte address limit which Windows doesn’t even support yet. In fact, Windows limits VAS to 8TB but physical memory is limited to 2TB….today), there is no need to use any special APIs to address memory bigger than the VAS. In other words, SQL Server should be free to go back and just use plain ol’ VirtualAlloc() to allocate memory. Well….the developers of the product discovered that if they still use the AWE APIs to allocate memory even though it is not really needed, two things would happen:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;A small performance gain occurs within the kernel. For more details, read this blog post from Slava Oks: &lt;a title="http://blogs.msdn.com/slavao/archive/2005/04/29/413425.aspx" href="http://blogs.msdn.com/slavao/archive/2005/04/29/413425.aspx"&gt;http://blogs.msdn.com/slavao/archive/2005/04/29/413425.aspx&lt;/a&gt; &lt;/li&gt;    &lt;li&gt;Just as with 32bit systems, any memory allocated using&amp;#160; the AWE API is not part of the working set and therefore cannot be paged to disk. Therefore it is considered “locked”. &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;Thus was born the concept most refer to as “locked pages” for 64bit SQL Server editions.&lt;/p&gt;  &lt;p&gt;Now remember the requirement to use the AWE APIs for any Windows application? The user account running the process must have the “Locked Pages in Memory” privilege set. So in the 64bit SQL Server engine, if this privilege is set (and a SKU check. See a different FAQ below for more discussion on this), we internally use the AWE APIs to allocate memory. By using the AWE APIs, we have in effect enabled a “locked pages” feature for the SQL Server engine.&lt;/p&gt;  &lt;p&gt;So in summary the AWE APIs for 32bit and 64bit SQL Server systems are used for different purposes. In 32bit it is really to extend memory access beyond 4Gb or to enable the AWE feature. For 64bit systems, it is to possibly gain performance and to “lock pages” for the buffer pool.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;2. Do I need to use the “awe enabled” sp_configure option on 64bit systems for SQL Server to “lock pages”?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;No. In fact, the code for SQL Server for 64bit systems ignores this sp_configure option. It is a “no-op” for 64bit SQL Server systems. You may ask why is this the case if I just told you that AWE APIs are used in 64bit SQL Server systems to “lock pages”?&lt;/p&gt;  &lt;p&gt;The answer is based on the purpose for that sp_configure option. The purpose of this sp_configure option on 32bit systems is for the user to “enable” the “AWE” feature, which is I explained above is to extend the ability to reference memory &amp;gt; 4Gb. Now as I mentioned already in order to use the AWE APIs you must have the “Locked Pages in Memory” Privilege. So, when you try to use sp_configure to set ‘awe enabled’ on a 32bit we actually will fail this command if “Locked Pages in Memory” is not set.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;3. Why is Task Manager not showing all of the memory allocated for SQL Server?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Imagine you walk up to a 64bit SQL Server installation and the customer tells you the computer has 8Gb of physical memory and SQL Server perfmon counters such as “Total Server Memory” show SQL Server is using around 3Gb of that. But you open up Task Manager on this Windows Server 2008 machine and look at the columns for SQLSERVR.EXE in Task Manager and see something like this:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/FunwithLockedPagesAWETaskManagerandtheWo_8C44/image_6.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/FunwithLockedPagesAWETaskManagerandtheWo_8C44/image_thumb_2.png" width="611" height="450" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;You can see in this example, that the column for “Memory” for Task Manager shows only ~135Mb. But on this computer, if I look at Perfmon and show Total Server Memory, I see this:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/FunwithLockedPagesAWETaskManagerandtheWo_8C44/image_10.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/FunwithLockedPagesAWETaskManagerandtheWo_8C44/image_thumb_4.png" width="616" height="518" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;Why the difference? Well, the most likely reason is that this SQL Server 64bit instance is using “locked pages” as I’ve described in an earlier question. Notice the name on the Task Manager column is called &lt;strong&gt;Memory (Private Working Set). &lt;/strong&gt;Remember we also said that if SQL Server 64bit instances use “locked pages” this memory would not be part of the working set (because remember AWE APIs are used on 64bit to “lock” pages and that memory is not part of the working set). So since the locked pages are not part of the working set, they won’t appear in this column in Task Manager. On the Task Manager for Windows Server 2003, this column is called “Mem Usage” but it also reflects the working set of the process.&lt;/p&gt;  &lt;p&gt;How can we prove this “difference” in memory is due to locked pages? Well, there are several ways to do this, but one way to easily see this in SQL Server 2008 is to query the sys.dm_os_process_memory DMV. On my computer where I saw this behavior I queried this DMV and saw these results:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/FunwithLockedPagesAWETaskManagerandtheWo_8C44/image_14.png"&gt;&lt;img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blogs.msdn.com/blogfiles/psssql/WindowsLiveWriter/FunwithLockedPagesAWETaskManagerandtheWo_8C44/image_thumb_6.png" width="571" height="319" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;You can see from this DMV that the column locked_page_allocations_kb is close to the Total Server Memory perfmon counter and shows that this memory is actually “locked”.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;4. Now I know that SQL Server on x64 can use “Locked Pages”, what exactly is locked?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;The simple, direct answer to this question is any memory allocated through the Buffer Pool Manager for SQL Server. But what is the “Buffer Pool Manager”? Does this mean only “database” pages are locked? Starting in SQL Server 2005, all memory allocations (in other words all access to the Windows API for memory) go through the SQLOS component of the engine. Any code in the SQL engine that need to allocate memory &amp;lt;= 8Kb use something called the “Single Page Allocator” (SPA) in SQLOS. It just so happens that SQLOS redirects any SPA requests to the Buffer Pool Manager. This is the same buffer pool code that has been used since SQL 7.0 to allocate memory. So any memory needed in the engine that wants “single pages” ultimately goes through the Buffer Pool. And… the Buffer Pool is the code that has the logic to lock pages via the AWE APIs.&lt;/p&gt;  &lt;p&gt;So…any code using the Single Page Allocator (SPA) which uses the Buffer Pool manager, will have its memory “locked” if the Buffer Pool Manager is using locked pages. What code uses the Single Page Allocator? Aside from the what you may already guess which are database pages, you can find out what “type” of memory uses the SPA by querying the sys.dm_os_memory_clerks DMV. Look for any row where the single_pages_kb column is &amp;gt; 0.&amp;#160; If you run this query on your server you are likely to see clerk types of CACHESTORE_OBJCP and CACHESTORE_SQLCP. This procedure cache memory. I won’t list out all of them here but you can see several “types” of memory use SPA which means they use Buffer Pool which means this memory can be locked.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;5. Does the Standard Edition of SQL Server 32bit support AWE? What about “Locked Pages” for 64bit?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;I’ve seen some people ask me and others at Microsoft whether the Standard Edition of SQL Server for 32bit supports the “AWE” feature. I think the confusion is related to the fact that Standard Edition for SQL Server for 64bit until recently did not support locked pages.&lt;/p&gt;  &lt;p&gt;So let’s dispel this myth here:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;The Standard Edition of SQL Server for 2005 and 2008 32bit DOES support the AWE feature. One source to confirm this is at &lt;a title="http://msdn.microsoft.com/en-us/library/cc645993.aspx" href="http://msdn.microsoft.com/en-us/library/cc645993.aspx"&gt;http://msdn.microsoft.com/en-us/library/cc645993.aspx&lt;/a&gt;. This lists “Dynamic AWE” as a feature support for both Standard and Enterprise Editions. As I wrote this blog I wanted to confirm this by going to the source..literally. I checked our code and our logic to “enable AWE” is based on Enterprise OR Standard Editions. &lt;/li&gt;    &lt;li&gt;Up until recently the Standard Edition of SQL Server 2005 and 2008 64bit did NOT support the “locked pages” feature as I’ve described it earlier in this blog post. Based on customer feedback we changed this in recent cumulative updates for both 2005 and 2008.&amp;#160; Enabling this for Standard requires a trace flag and you can read more about this at &lt;a title="http://blogs.msdn.com/psssql/archive/2009/05/19/an-update-for-standard-sku-support-for-locked-pages.aspx" href="http://blogs.msdn.com/psssql/archive/2009/05/19/an-update-for-standard-sku-support-for-locked-pages.aspx"&gt;http://blogs.msdn.com/psssql/archive/2009/05/19/an-update-for-standard-sku-support-for-locked-pages.aspx&lt;/a&gt; &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&lt;strong&gt;6. How do I know if AWE is enabled on a 32bit SQL Server? How do I know if “Locked Pages” is working on a 64bit SQL Server?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Read this blog post first which gives details on the algorithm in the engine for enabling AWE or for enabling “Locked Pages” &lt;a title="http://blogs.msdn.com/psssql/archive/2007/10/18/do-i-have-to-assign-the-lock-privilege-for-local-system.aspx" href="http://blogs.msdn.com/psssql/archive/2007/10/18/do-i-have-to-assign-the-lock-privilege-for-local-system.aspx"&gt;http://blogs.msdn.com/psssql/archive/2007/10/18/do-i-have-to-assign-the-lock-privilege-for-local-system.aspx&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;For 32bit systems, one tip. If you think you set “awe enabled” to 1 and are not sure why you are not seeing &lt;strong&gt;Address Windowing Extensions is enabled&lt;/strong&gt; in the ERRORLOG, it is likely you either didn’t run RECONFIGURE after changing “awe enabled” to 1 OR the “Lock Pages in Memory” privilege is not set. If you try to reconfigure after changing “awe enabled” to 1 and the “Lock Pages in Memory” privilege is not set, the RECONFIGURE command will fail with:&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Msg 5845, Level 16, State 1, Line 1      &lt;br /&gt;Address Windowing Extensions (AWE) requires the 'lock pages in memory' privilege which is not currently present in the access token of the process.&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;I hope this information has helped you understand the concepts of AWE and “Locked Pages” with respect to SQL Server. I know this can be a confusing topic and I don’t blame anyone for asking question to understand this. If I see comments to this post or run into any common questions that make sense I’ll add this to the FAQ on this blog.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Bob Ward    &lt;br /&gt;Microsoft&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9894354" width="1" height="1"&gt;</content><author><name>psssql</name><uri>http://blogs.msdn.com/members/psssql.aspx</uri></author><category term="Memory" scheme="http://blogs.msdn.com/psssql/archive/tags/Memory/default.aspx" /></entry></feed>