Comments on: When To Use Auto Shrink https://thomaslarock.com/2009/03/when-to-use-auto-shrink/ Thomas LaRock is an author, speaker, data expert, and SQLRockstar. He helps people connect, learn, and share. Along the way he solves data problems, too. Wed, 11 Jan 2017 22:29:00 +0000 hourly 1 https://wordpress.org/?v=6.7.1 By: ThomasLaRock https://thomaslarock.com/2009/03/when-to-use-auto-shrink/#comment-15800 Wed, 11 Jan 2017 22:29:00 +0000 http://sqlbatman.com/?p=1295#comment-15800 In reply to Michael Spurlock.

Michael,

Thanks for the comment. This blog post is almost 8 years old now. It could use some updating.

There are some valid reasons for wanting to reclaim disk space. The scenario I wrote about here is not one of them. The scenario you mention could be one, sure.

I don’t believe that this is a fault of the SQL Server design. I’m not certain I’d want a RDBMS to be actively trying to prune space, that seems to me to be more overhead than necessary. I would also consider the issue of fragmentation, but with flash storage fragmentation isn’t much of an issue anymore.

Thanks again for the comment. I should consider writing an updated post.

]]>
By: Michael Spurlock https://thomaslarock.com/2009/03/when-to-use-auto-shrink/#comment-15796 Wed, 11 Jan 2017 17:15:00 +0000 http://sqlbatman.com/?p=1295#comment-15796 So if you delete or redact massive amounts of data from a column in your lower environments, you’re just supposed to be happy that the inefficient SQL Server design continues to claim that disk space?
When is Microsoft going to address this dog-ass design?
“Drive space is cheap” does NOT address budgetary issues or government regulations.

]]>
By: Shrink SQL Server Databases for Mirroring & Availability Groups https://thomaslarock.com/2009/03/when-to-use-auto-shrink/#comment-14756 Sun, 24 Jul 2016 06:37:56 +0000 http://sqlbatman.com/?p=1295#comment-14756 […] Tom LaRock – “When to Use AutoShrink” […]

]]>
By: Shrink SQL Server Databases for Mirroring & Availability Groups https://thomaslarock.com/2009/03/when-to-use-auto-shrink/#comment-14755 Sun, 24 Jul 2016 06:37:56 +0000 http://sqlbatman.com/?p=1295#comment-14755 […] Tom LaRock – “When to Use AutoShrink” […]

]]>
By: Shrinking Database Data Files | Simple SQL Server https://thomaslarock.com/2009/03/when-to-use-auto-shrink/#comment-13570 Tue, 19 Jan 2016 12:01:54 +0000 http://sqlbatman.com/?p=1295#comment-13570 […] be fair, we all word our feelings on this differently.  I say no, Tom LaRock says never, Paul Randal says Turn It Off!, and Brent Ozar is colorful enough to come up with the term Hamster […]

]]>
By: Cranky Series: Don’t Enable Autoshrink. Ever. https://thomaslarock.com/2009/03/when-to-use-auto-shrink/#comment-7242 Fri, 10 Aug 2012 12:08:22 +0000 http://sqlbatman.com/?p=1295#comment-7242 […] believe me? Don’t believe Paul? Maybe you’ll believe Tom. But whatever you do, disable autoshrink. SQLServerPedia […]

]]>
By: Forrest Pugh https://thomaslarock.com/2009/03/when-to-use-auto-shrink/#comment-6782 Sat, 17 Mar 2012 03:00:00 +0000 http://sqlbatman.com/?p=1295#comment-6782 I think the only situation in which I can recommend this one similar to our shop – because of audit requirements we need to keep a copy of the data at each step of the import/append/analyze process. Of course we are pretty vertical in our processing and availability is not so much of a factor.

With several “mirror” databases supporting the main analysis process, shrinking any transaction logs and datafiles in these dbs before archiving is essentially a requirement – the integrity of the data tables themselves is all that really matters.

Likewise discrete analyses are done in separate databases extracted from an appended set. In these DBs many process tables are created that are not required for the final reporting, and likewise a number of statistics and indices are generated that will not be used after the reporting is complete. The overhead objects can be lost entirely, and the space released before detaching and archiving.

While this is a very atypical scenario – if you work in an environment where the ability to reproduce exactly a certain result set is necessary this can be fairly bullet proof, but it DOES eat up quite a bit of storage space – so removing the unnecessary information and then compacting the files as much as possible is sort of an implicit requirement.

And as Brant says – every once in a while someone might need to do a query on one of these historical sets which has not yet been shipped off to archive.

]]>