<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Archives des autogrow - dbi Blog</title>
	<atom:link href="https://www.dbi-services.com/blog/tag/autogrow/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.dbi-services.com/blog/tag/autogrow/</link>
	<description></description>
	<lastBuildDate>Thu, 17 Mar 2016 20:48:07 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	

<image>
	<url>https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2025/05/cropped-favicon_512x512px-min-32x32.png</url>
	<title>Archives des autogrow - dbi Blog</title>
	<link>https://www.dbi-services.com/blog/tag/autogrow/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>SQL Server 2016: new database-scoped configuration parameters</title>
		<link>https://www.dbi-services.com/blog/sql-server-2016-new-database-scoped-configuration-parameters/</link>
					<comments>https://www.dbi-services.com/blog/sql-server-2016-new-database-scoped-configuration-parameters/#respond</comments>
		
		<dc:creator><![CDATA[Microsoft Team]]></dc:creator>
		<pubDate>Thu, 17 Mar 2016 20:48:07 +0000</pubDate>
				<category><![CDATA[Database Administration & Monitoring]]></category>
		<category><![CDATA[autogrow]]></category>
		<category><![CDATA[AUTOGROW_ALL_FILES]]></category>
		<category><![CDATA[AUTOGROW_SINGLE_FILE]]></category>
		<category><![CDATA[database scoped parameters]]></category>
		<category><![CDATA[mixed extent]]></category>
		<category><![CDATA[MIXED_PAGE_ALLOCATION]]></category>
		<category><![CDATA[page allocation]]></category>
		<category><![CDATA[SQL Server 2016]]></category>
		<category><![CDATA[uniform extent]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/sql-server-2016-new-database-scoped-configuration-parameters/</guid>

					<description><![CDATA[<p>Do you remember new capabilities shipped with SQL Server 2016 CTP2 about tempdb? In this blog post, I talked about well-known trace flags 1117 and 1118 that become useless for tempdb because their related effects are automatically applied to tempdb. Another interesting news that comes from the new SQL Server 2016 RC0 is the use [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-2016-new-database-scoped-configuration-parameters/">SQL Server 2016: new database-scoped configuration parameters</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Do you remember new capabilities shipped with SQL Server 2016 CTP2 about tempdb? In this <a href="http://dbi-services.com/blog/sql-server-2016-ctp2-first-thoughts-about-tempdb-database/" target="_blank" rel="noopener noreferrer">blog post</a>, I talked about well-known trace flags 1117 and 1118 that become useless for tempdb because their related effects are automatically applied to tempdb.</p>
<p>Another interesting news that comes from the new SQL Server 2016 RC0 is the use of new database-scoped parameters AUTOGROW_SINGLE_FILE / AUTOGROW_ALL_FILES as well as MIXED_PAGE_ALLOCATION that will replace respectively the effects of the 1117 and 1118 trace flags for a particular database. This is a very great news because we will benefit of a more granular configuration regarding our specific workload against one particular database.</p>
<p>Let’s create this simple database and let’s enable the AUTOGROW_ALL_FILES on the primary filegroup</p>
<pre class="brush: sql; gutter: true; first-line: 1">CREATE DATABASE [DB_2016]
 ON  PRIMARY 
( NAME = N'DB_2016', FILENAME = N'E:\SQLSERVER\SQL16\DB_2016.mdf' , SIZE = 524288KB , FILEGROWTH = 65536KB ),
( NAME = N'DB_20162', FILENAME = N'E:\SQLSERVER\SQL16\DB_20162.ndf' , SIZE = 524288KB , FILEGROWTH = 65536KB ),
( NAME = N'DB_20163', FILENAME = N'E:\SQLSERVER\SQL16\DB_20163.ndf' , SIZE = 524288KB , FILEGROWTH = 65536KB )
 LOG ON 
( NAME = N'DB_2016_log', FILENAME = N'F:\SQLSERVER\SQL16\DB_2016_log.ldf' , SIZE = 524288KB , FILEGROWTH = 65536KB )
GO

ALTER DATABASE [DB_2016]
MODIFY FILEGROUP [PRIMARY] AUTOGROW_ALL_FILES;
GO</pre>
<p>&nbsp;</p>
<p>The <em>sys.filegroups</em> system view has a new <em>is_autogrow_files</em> column to check if all files in the same filegroup will grow at the same time</p>
<pre class="brush: sql; gutter: true; first-line: 1">USE [DB_2016];
GO

SELECT 
	DB_NAME() AS [db_name],
	mf.name AS logical_name,
	fg.name as [filegroup_name],
	fg.is_autogrow_all_files
FROM sys.database_files AS mf
JOIN sys.filegroups AS fg
	ON mf.data_space_id = fg.data_space_id
GO</pre>
<p>&nbsp;</p>
<p><a href="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-1-AUTOGROW_ALL_FILES.jpg"><img decoding="async" class="alignnone size-full wp-image-7604" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-1-AUTOGROW_ALL_FILES.jpg" alt="blog 84 - 1 - AUTOGROW_ALL_FILES" width="467" height="100" /></a></p>
<p>Let&#8217;s validate this new option with the following pretty simple test:</p>
<pre class="brush: sql; gutter: true; first-line: 1">CREATE TABLE dbo.test_2016
(
	id INT IDENTITY,
	col1 CHAR(8000) DEFAULT 'T'
);
GO

INSERT INTO dbo.test_2016 DEFAULT VALUES;
GO 210000</pre>
<p>&nbsp;</p>
<p>File sizes have increased as expected by refering to the following query output:</p>
<pre class="brush: sql; gutter: true; first-line: 1">SELECT 
	name AS logical_name,
	size / 128 AS size_mb,
	CAST(FILEPROPERTY(name, 'SpaceUsed') * 100. / size AS DECIMAL(5, 2)) AS [%_free]
FROM sys.database_files
WHERE type_desc = 'ROWS'</pre>
<p>&nbsp;</p>
<p><a href="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-2-new-file-sizes.jpg"><img decoding="async" class="alignnone size-full wp-image-7605" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-2-new-file-sizes.jpg" alt="blog 84 - 2 - new file sizes" width="273" height="100" /></a></p>
<p>All files seem to have grown with the same target size at the same time according to events found in the default trace.</p>
<pre class="brush: sql; gutter: true; first-line: 1">DECLARE @path NVARCHAR(260);

SELECT 
   @path = REVERSE(SUBSTRING(REVERSE([path]), 
   CHARINDEX('\', REVERSE([path])), 260)) + N'log.trc'
FROM    sys.traces
WHERE   is_default = 1;

SELECT 
   DatabaseName,
   [FileName],
   SPID,
   Duration,
   StartTime,
   EndTime,
   FileType = CASE EventClass 
       WHEN 92 THEN 'Data'
       WHEN 93 THEN 'Log'
   END
FROM sys.fn_trace_gettable(@path, DEFAULT)
WHERE EventClass = 92
	AND DatabaseName = 'DB_2016'
ORDER BY StartTime DESC;</pre>
<p>&nbsp;</p>
<p><a href="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-3-autogrow-event.jpg"><img fetchpriority="high" decoding="async" class="alignnone size-full wp-image-7606" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-3-autogrow-event.jpg" alt="blog 84 - 3 - autogrow event" width="768" height="100" /></a></p>
<p>In the next scenario, let’s test the effect of the second interesting MIXED_PAGE_ALLOCATION option. Let’s say we want to disable the allocation of mixed extents (default behavior) by using the following command:</p>
<pre class="brush: sql; gutter: true; first-line: 1">ALTER DATABASE [DB_2016] SET MIXED_PAGE_ALLOCATION OFF;
GO</pre>
<p>&nbsp;</p>
<p>As the previous database-scoped option we are able to control which databases are candidate for mixed or uniform allocations by default. This information is directly accessible from the <em>sys.databases</em> DMV as shown below:</p>
<pre class="brush: sql; gutter: true; first-line: 1">SELECT 
	name, is_mixed_page_allocation_on
FROM sys.databases</pre>
<p>&nbsp;</p>
<p><a href="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-4-mixed-extent-info-sys_databases.jpg"><img loading="lazy" decoding="async" class="alignnone size-full wp-image-7607" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-4-mixed-extent-info-sys_databases.jpg" alt="blog 84 - 4 - mixed extent info sys_databases" width="327" height="168" /></a></p>
<p>You may notice that we are now able to confirm that mixed extent allocation is disabled by default for our user database and tempdb as well (without enabling the trace flag 1118).</p>
<p>Let’s perform the quick test of verifying if uniform extend is the default behavior for the DB_2016 database (my database is in SIMPLe recovery model here)</p>
<pre class="brush: sql; gutter: true; first-line: 1">CHECKPOINT;

CREATE TABLE dbo.test_20161
(
	id INT IDENTITY,
	col1 CHAR(8000) DEFAULT 'T'
);
GO

INSERT INTO dbo.test_20161 DEFAULT VALUES;
GO 1</pre>
<p>Let’s verify the context of the DB_2016 database transaction log. We may notice the related record that confirms a new uniform extent is allocated of the concerned <em>dbo.test_20161</em> table as shown below:</p>
<p><a href="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-5-fn_dblog.jpg"><img loading="lazy" decoding="async" class="alignnone size-large wp-image-7608" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-5-fn_dblog.jpg" alt="blog 84 - 5 - fn_dblog" width="1024" height="176" /></a></p>
<p>We may also double check by using the <em>sys.dm_db_database_page_allocations</em> DMF against the same table as following:</p>
<pre class="brush: sql; gutter: true; first-line: 1">SELECT 
	OBJECT_NAME(object_id) AS table_name,
	index_id,
	[partition_id],
	extent_page_id,
	allocated_page_page_id,
	page_type_desc as page_type
FROM sys.dm_db_database_page_allocations(DB_ID(), OBJECT_ID('dbo.test_20161'), 0, NULL, 'DETAILED')</pre>
<p>&nbsp;</p>
<p><a href="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-6-DMF.jpg"><img loading="lazy" decoding="async" class="alignnone size-full wp-image-7609" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog-84-6-DMF.jpg" alt="blog 84 - 6 - DMF" width="671" height="247" /></a></p>
<p>Stay tuned! In the next blog we’ll see other interesting database-scoped options provided with the future release of SQL Server 2016.</p>
<p>By David Barbarin</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>L’article <a href="https://www.dbi-services.com/blog/sql-server-2016-new-database-scoped-configuration-parameters/">SQL Server 2016: new database-scoped configuration parameters</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/sql-server-2016-new-database-scoped-configuration-parameters/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Don&#8217;t use the default database file autogrow settings !</title>
		<link>https://www.dbi-services.com/blog/dont-use-the-default-database-file-autogrow-settings/</link>
					<comments>https://www.dbi-services.com/blog/dont-use-the-default-database-file-autogrow-settings/#respond</comments>
		
		<dc:creator><![CDATA[Microsoft Team]]></dc:creator>
		<pubDate>Mon, 13 Jul 2015 17:37:07 +0000</pubDate>
				<category><![CDATA[Application integration & Middleware]]></category>
		<category><![CDATA[autogrow]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[Performance]]></category>
		<category><![CDATA[SQL Server]]></category>
		<guid isPermaLink="false">https://www.dbi-services.com/blog/dont-use-the-default-database-file-autogrow-settings/</guid>

					<description><![CDATA[<p>I often noticed default values for database file autogrow settings during my audits. You don&#8217;t trust me? Let me talk about a funny story about an incredible (and extreme) situation that concerns a transaction log file and its default settings. First of all, during my intervention, my customer complained of some performance issues, so I [&#8230;]</p>
<p>L’article <a href="https://www.dbi-services.com/blog/dont-use-the-default-database-file-autogrow-settings/">Don&#8217;t use the default database file autogrow settings !</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I often noticed default values for database file autogrow settings during my audits. You don&#8217;t trust me? Let me talk about a funny story about an incredible (and extreme) situation that concerns a transaction log file and its default settings.</p>
<p>First of all, during my intervention, my customer complained of some performance issues, so I decided to take a look at different areas of its instance.</p>
<p>I found some interesting records inside the SQL Server error log file as follows:</p>
<p><img loading="lazy" decoding="async" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog_56_-_2_-_timeout_latch_log_manager_2_dump.jpg" alt="blog_56_-_2_-_timeout_latch_log_manager_2_dump" width="618" height="287" /></p>
<p>A timeout that occurred while waiting for latch class LOG_MANAGER … Ouch, it was the first time I faced this issue and after taking a look at the latch stats it confirmed that an issue existed on this area:</p>
<p><img loading="lazy" decoding="async" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog_56_-_3_-_latch_stats.jpg" alt="blog_56_-_3_-_latch_stats" width="396" height="42" /></p>
<p>Unfortunately, the Microsoft documentation is very poor concerning the description of this latch type.</p>
<p><img loading="lazy" decoding="async" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog_56_-_4_-_LOG_MANAGER_desc.jpg" alt="blog_56_-_4_-_LOG_MANAGER_desc" width="357" height="34" /></p>
<p>But <a href="https://twitter.com/PaulRandal">Paul Randal</a> gives some clues on his very useful blog <a href="http://www.sqlskills.com/blogs/paul/most-common-latch-classes-and-what-they-mean/">here</a>. This latch may appear when transaction log file is growing (whatever the reason). After some investigations, I effectively found that the growing issue was due to an incorrect recovery model configuration (FULL and no backup log in this context).</p>
<p>But that’s not all and this is where the funny part of this story comes. To be honest, I have never seen a latch timeout causing by a growing of a transaction log file except on this situation. I first suspected the storage here but in fact after taking a look at the transaction log file size and the associated growth parameter, I definitely rule out this suspicion (at least the real problem was not here).</p>
<p><img loading="lazy" decoding="async" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog_56_-_5_-_log_space_used.jpg" alt="blog_56_-_5_-_log_space_used" width="391" height="122" /></p>
<p>&#8230;</p>
<p><img loading="lazy" decoding="async" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog_56_-_6_-_database_file_options.jpg" alt="blog_56_-_6_-_database_file_options" width="629" height="34" /></p>
<p><span style="font-size: 11pt;line-height: 107%;font-family: 'Calibri',sans-serif">I replaced the real database name of my customer by <strong><em>User DB</em></strong> here. So what do you notice? No you don’t dream … the transaction log file size = 1.2 TB with a default auto growth configuration = 10%! So I imagine that you begin to understand where the problem is located</span> <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>
<p>So, just for curiosity let’s have a look at the generated dump file:</p>
<p><img loading="lazy" decoding="async" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog_56_-_7_-_dump_reading.jpg" alt="blog_56_-_7_-_dump_reading" width="506" height="392" /></p>
<p>So, it seems that an update query has generated log records after updating a BTree structure (<em>sqlmin!BTreeRow:UpdateRecord())</em>. In turn, the log manager tried to expand the transaction log file (<em>sqlmin!SQLServerLogMgr::GrowAFile()</em> method) without success after SQL Server has generated log records (<em>sqlmin!XdesRMReadWrite::LogBeginXact()</em> &#8211;&gt; <em>sqlmin!XdesRMReadWrite:GenerateLogRec()</em> methods) . In this context, I guess that the expand operation has taken a very long time because 10% of the transaction log file represents a large chunk of disk space (roughly 100GB).</p>
<p>Finally let&#8217;s have a look at the wait stats:</p>
<p><img loading="lazy" decoding="async" src="https://www.dbi-services.com/blog/wp-content/uploads/sites/2/2022/04/blog_56_-_1_-_wait_stats.jpg" alt="blog_56_-_1_-_wait_stats" width="626" height="136" /></p>
<p>We can also correlate the PREEMPTIVE_OS_WRITEFILEGATHER wait type to our issue here with the high average value. Zeroing the new portion of the transaction log file may be very long in our context.</p>
<p>My intention was not to blame my customer here but it was a good opportunity to point out the potential issue you may face with default database file auto growth settings!</p>
<p>See you</p>
<p>By David Barbarin</p>
<p>L’article <a href="https://www.dbi-services.com/blog/dont-use-the-default-database-file-autogrow-settings/">Don&#8217;t use the default database file autogrow settings !</a> est apparu en premier sur <a href="https://www.dbi-services.com/blog">dbi Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbi-services.com/blog/dont-use-the-default-database-file-autogrow-settings/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Lazy Loading (feed)

Served from: www.dbi-services.com @ 2026-10-17 20:25:14 by W3 Total Cache
-->